Use non-root nginx base in Docker image

This commit is contained in:
Quentin Gliech 2022-02-02 15:33:10 +01:00
parent ea5723cb32
commit 43b043c565
No known key found for this signature in database
GPG Key ID: 22D62B84552719FC
2 changed files with 2 additions and 2 deletions

View File

@ -10,5 +10,5 @@ RUN yarn install
COPY . . COPY . .
RUN yarn build RUN yarn build
FROM --platform=${TARGETPLATFORM} docker.io/library/nginx:alpine FROM --platform=${TARGETPLATFORM} docker.io/nginxinc/nginx-unprivileged:1.21-alpine
COPY --from=builder /app/target /usr/share/nginx/html COPY --from=builder /app/target /usr/share/nginx/html

View File

@ -55,6 +55,6 @@ Then, start up a container from that image:
``` ```
docker run \ docker run \
--name hydrogen \ --name hydrogen \
--publish 80:80 \ --publish 8080:80 \
hydrogen hydrogen
``` ```