# 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;"]