Fix container build
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
# Production Dockerfile for MotoVaultPro Frontend
|
||||
FROM node:20-alpine as build
|
||||
FROM node:20-alpine AS build
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /app
|
||||
@@ -25,9 +25,8 @@ COPY --from=build /app/dist /usr/share/nginx/html
|
||||
# Copy nginx configuration
|
||||
COPY nginx.conf /etc/nginx/nginx.conf
|
||||
|
||||
# Create non-root user for nginx
|
||||
RUN addgroup -g 1001 -S nginx && \
|
||||
adduser -S frontend -u 1001 -G nginx
|
||||
# Create non-root user for nginx (nginx group already exists)
|
||||
RUN adduser -S frontend -u 1001 -G nginx
|
||||
|
||||
# Change ownership of nginx directories
|
||||
RUN chown -R frontend:nginx /var/cache/nginx && \
|
||||
|
||||
Reference in New Issue
Block a user