mirror of
https://github.com/taylanbakircioglu/flowfish.git
synced 2026-09-12 05:48:55 +00:00
d5f9b1833d
The frontend image was flagged on nginx 1.31.0 because the Dockerfiles used the floating nginx:alpine (mainline) tag. No rewrite directives exist in any nginx config, so the named-capture mitigation does not apply; the remediation is the version update. Pin every nginx reference to the patched 1.31.1-alpine release: - frontend/Dockerfile, Dockerfile.production, Dockerfile.simple - deployment/local-test/14-nginx-proxy.yaml (was nginx:alpine) - deployment/local-test/l7-sample-apps.yaml (was nginx:1.25-alpine) Validated with `nginx -t` on 1.31.1 for all configs.
31 lines
829 B
Docker
31 lines
829 B
Docker
# Simple static frontend for MVP
|
|
# Pinned to a patched nginx release (>= 1.31.1) to remediate the "poolslip"
|
|
# advisory; the floating nginx:alpine tag previously shipped vulnerable 1.31.0.
|
|
FROM nginx:1.31.1-alpine
|
|
|
|
# Remove default nginx website
|
|
RUN rm -rf /usr/share/nginx/html/*
|
|
|
|
# Copy static MVP HTML
|
|
COPY public/mvp.html /usr/share/nginx/html/index.html
|
|
|
|
# Copy nginx configuration
|
|
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
|
|
|
# Create non-root user
|
|
RUN addgroup -g 101 -S nginx && \
|
|
adduser -S -D -H -u 101 -h /var/cache/nginx -s /sbin/nologin -G nginx -g nginx nginx 2>/dev/null || true
|
|
|
|
# Change ownership
|
|
RUN chown -R nginx:nginx /usr/share/nginx/html /var/cache/nginx /var/log/nginx /etc/nginx
|
|
|
|
# Switch to non-root user
|
|
USER nginx
|
|
|
|
# Expose port
|
|
EXPOSE 3000
|
|
|
|
# Start nginx
|
|
CMD ["nginx", "-g", "daemon off;"]
|
|
|