feat(docker): switch to Chainguard nginx image
Replace nginx:alpine with cgr.dev/chainguard/nginx base image and remove unnecessary permission changes since the Chainguard image handles permissions differently and runs with proper security defaults.
This commit is contained in:
parent
6c891cb131
commit
2458af460b
1 changed files with 1 additions and 8 deletions
|
|
@ -12,7 +12,7 @@ COPY nginx.conf /etc/nginx/conf.d/default.conf
|
|||
|
||||
|
||||
# Default step in docker build
|
||||
FROM nginx:alpine
|
||||
FROM cgr.dev/chainguard/nginx
|
||||
LABEL maintainer=Rajesh<rajesh@openreplay.com>
|
||||
ARG GIT_SHA
|
||||
LABEL GIT_SHA=$GIT_SHA
|
||||
|
|
@ -22,10 +22,3 @@ COPY nginx.conf /etc/nginx/conf.d/default.conf
|
|||
ENV GIT_SHA=$GIT_SHA
|
||||
|
||||
EXPOSE 8080
|
||||
RUN chown -R nginx:nginx /var/cache/nginx && \
|
||||
chown -R nginx:nginx /var/log/nginx && \
|
||||
chown -R nginx:nginx /etc/nginx/conf.d && \
|
||||
touch /var/run/nginx.pid && \
|
||||
chown -R nginx:nginx /var/run/nginx.pid
|
||||
|
||||
USER nginx
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue