diff --git a/apps/web/Caddyfile b/apps/web/Caddyfile new file mode 100644 index 000000000..0e343706b --- /dev/null +++ b/apps/web/Caddyfile @@ -0,0 +1,6 @@ +:80 { + root * /srv + encode gzip zstd + try_files {path} /index.html + file_server +} diff --git a/apps/web/Dockerfile b/apps/web/Dockerfile index 80e31284c..3b7de50e1 100644 --- a/apps/web/Dockerfile +++ b/apps/web/Dockerfile @@ -22,7 +22,9 @@ RUN pnpm install --frozen-lockfile RUN turbo build --filter=@opendatacapture/web # RUN SERVER -FROM base AS runner -RUN pnpm install -g @import-meta-env/cli@0.6.8 http-server@14.1.1 -COPY --from=installer /app/apps/web/.env.public /app/apps/web/dist/ ./ -CMD [ "sh", "-c", "import-meta-env -x .env.public -p index.html && http-server -s -p 80 -P http://localhost:80? --gzip ." ] +FROM caddy:2.7-alpine AS runner +RUN apk add --no-cache nodejs npm +RUN npm install -g @import-meta-env/cli@0.6.8 +COPY apps/web/Caddyfile /etc/caddy/Caddyfile +COPY --from=installer /app/apps/web/.env.public /app/apps/web/dist/ /srv/ +CMD [ "sh", "-c", "import-meta-env -x .env.public -p index.html && caddy run --config /etc/caddy/Caddyfile --adapter caddyfile" ] diff --git a/package.json b/package.json index 0f537b09e..19cb6b1a3 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "opendatacapture", "type": "module", - "version": "1.16.4", + "version": "1.16.5", "private": true, "packageManager": "pnpm@10.34.1", "license": "Apache-2.0", diff --git a/packages/instrument-bundler/package.json b/packages/instrument-bundler/package.json index b59faf45f..f3b4c5b0c 100644 --- a/packages/instrument-bundler/package.json +++ b/packages/instrument-bundler/package.json @@ -1,7 +1,7 @@ { "name": "@opendatacapture/instrument-bundler", "type": "module", - "version": "1.16.4", + "version": "1.16.5", "license": "Apache-2.0", "publishConfig": { "access": "public" diff --git a/packages/instrument-guidelines/package.json b/packages/instrument-guidelines/package.json index c452ebec7..beb058c5c 100644 --- a/packages/instrument-guidelines/package.json +++ b/packages/instrument-guidelines/package.json @@ -1,7 +1,7 @@ { "name": "@opendatacapture/instrument-guidelines", "type": "module", - "version": "1.16.4", + "version": "1.16.5", "description": "Guidelines for authoring Open Data Capture instruments, intended to be read by an AI agent (e.g. Claude Code).", "license": "Apache-2.0", "publishConfig": { diff --git a/packages/serve-instrument/package.json b/packages/serve-instrument/package.json index f974d2f19..d5d2b37e6 100644 --- a/packages/serve-instrument/package.json +++ b/packages/serve-instrument/package.json @@ -1,7 +1,7 @@ { "name": "@opendatacapture/serve-instrument", "type": "module", - "version": "1.16.4", + "version": "1.16.5", "license": "Apache-2.0", "publishConfig": { "access": "public" diff --git a/runtime/v1/package.json b/runtime/v1/package.json index 8c1c5e485..eaba378f8 100644 --- a/runtime/v1/package.json +++ b/runtime/v1/package.json @@ -1,7 +1,7 @@ { "name": "@opendatacapture/runtime-v1", "type": "module", - "version": "1.16.4", + "version": "1.16.5", "author": { "name": "Douglas Neuroinformatics", "email": "support@douglasneuroinformatics.ca"