feat: fixes docker build

This commit is contained in:
2025-10-31 23:46:25 -03:00
parent e1a30d1227
commit c22012b1c8
2 changed files with 22 additions and 4 deletions

4
.dockerignore Normal file
View File

@@ -0,0 +1,4 @@
.github
.gitignore
Dockerfile
README.md

View File

@@ -1,16 +1,30 @@
FROM node:18-alpine
FROM node:22.12-alpine AS base
FROM base AS build
WORKDIR /app
COPY package*.json ./
RUN npm install
FROM base AS prod
WORKDIR /app
COPY --from=build /app/node_modules ./node_modules
COPY . .
RUN npm install -g @angular/cli@20.3.8
RUN apk add --update gettext python3 py3-pip py3-setuptools make g++ && \
rm -rf /var/cache/apk/*
RUN npm install
RUN npm install -g @angular/cli@16
RUN npm run build:prod
EXPOSE 5000-7000
CMD ["npm", "run", "start:prod"]