chore: Update Dockerfile base images, add system updates, and change exposed port to 8080.
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
# Estágio de Build
|
# Estágio de Build
|
||||||
FROM node:20-alpine as build-stage
|
FROM bitnami/node:22 as build-stage
|
||||||
|
RUN apt-get update && apt-get upgrade -y && apt-get clean && rm -rf /var/lib/apt/lists/*
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY package*.json ./
|
COPY package*.json ./
|
||||||
RUN npm install --frozen-lockfile || npm install
|
RUN npm install --frozen-lockfile || npm install
|
||||||
@@ -7,7 +8,8 @@ COPY . .
|
|||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
# Estágio de Produção
|
# Estágio de Produção
|
||||||
FROM nginx:stable-alpine as production-stage
|
FROM nginxinc/nginx-unprivileged:alpine as production-stage
|
||||||
|
RUN apk update && apk upgrade --no-cache
|
||||||
COPY --from=build-stage /app/dist /usr/share/nginx/html
|
COPY --from=build-stage /app/dist /usr/share/nginx/html
|
||||||
EXPOSE 80
|
EXPOSE 8080
|
||||||
CMD ["nginx", "-g", "daemon off;"]
|
CMD ["nginx", "-g", "daemon off;"]
|
||||||
|
|||||||
Reference in New Issue
Block a user