inserito tsconfig.build.json
Some checks failed
Deploy to VPS / build (push) Successful in 22s
Deploy to VPS / deploy (push) Failing after 16m46s

This commit is contained in:
AV77web 2026-07-12 03:18:43 +02:00
parent 5d01cd3437
commit 28e9bfd528
2 changed files with 32 additions and 0 deletions

28
dockerfile/Dockerfile Normal file
View file

@ -0,0 +1,28 @@
# syntax=docker/dockerfile:1
ARG NODE_VERSION=20
FROM node:${NODE_VERSION}-slim AS build
WORKDIR /app
COPY package*.json ./
RUN npm ci
COPY tsconfig.json tsconfig.build.json ./
COPY src ./src
RUN npm run build
FROM node:${NODE_VERSION}-slim AS runtime
WORKDIR /app
ENV NODE_ENV=production
ENV PORT=3011
COPY package*.json ./
RUN npm ci --omit=dev
COPY --from=build /app/dist ./dist
#COPY --from=build /app/src/openapi ./dist/openapi
EXPOSE 3001
CMD ["node", "dist/index.js"]

4
tsconfig.build.json Normal file
View file

@ -0,0 +1,4 @@
{
"extends": "./tsconfig.json",
"exclude": ["node_modules", "dist", "**/*.test.ts"]
}