fix: apply ceo-api's Dockerfile/tsconfig fixes to ceo-worker

Same two bugs found deploying ceo-api: npm ci needs --include=dev in
the build stage (Coolify exposes NODE_ENV=production at build time,
which makes npm skip devDependencies otherwise), and tsconfig needs an
explicit include filter to keep nest build's output at dist/main.js.
This commit is contained in:
valentinbvro 2026-07-21 19:18:59 +02:00
parent 064a1cb4b5
commit 7518682171
4 changed files with 4679 additions and 5 deletions

5
.dockerignore Normal file
View file

@ -0,0 +1,5 @@
node_modules
dist
.git
.env
*.log

View file

@ -1,14 +1,14 @@
FROM node:22-alpine AS build
WORKDIR /app
COPY package.json ./
RUN npm install
COPY package.json package-lock.json ./
RUN npm ci --legacy-peer-deps --include=dev
COPY . .
RUN npm run build
FROM node:22-alpine
WORKDIR /app
ENV NODE_ENV=production
COPY --from=build /app/node_modules ./node_modules
COPY package.json package-lock.json ./
RUN npm ci --legacy-peer-deps --omit=dev
COPY --from=build /app/dist ./dist
COPY package.json ./
CMD ["node", "dist/main"]

4668
package-lock.json generated Normal file

File diff suppressed because it is too large Load diff

View file

@ -16,5 +16,6 @@
"strictNullChecks": true,
"noImplicitAny": true,
"esModuleInterop": true
}
},
"include": ["src/**/*.ts"]
}