Improve deployment security

This commit is contained in:
2022-02-14 09:42:44 +00:00
parent a7b1891501
commit 9f8b2e7711
4 changed files with 30 additions and 25 deletions

View File

@@ -1,4 +1,4 @@
FROM reg.dev.krd/hub.docker/library/node:16 as build-stage
FROM node:16 as build-stage
WORKDIR /app
@@ -13,8 +13,7 @@ COPY *.js ./
RUN npm run build
FROM reg.dev.krd/hub.docker/library/nginx:1.20-alpine AS production
FROM bitnami/nginx:1.20 AS production
COPY --from=build-stage /app/build /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
COPY --from=build-stage /app/build /app
EXPOSE 8080