هذا الالتزام موجود في:
2025-09-30 16:33:50 +00:00
الأصل 09069cbd54
التزام 778471927b

32
Dockerfile Normal file
عرض الملف

@@ -0,0 +1,32 @@
# Stage 1: Build the React app
FROM node:18-alpine AS builder
# Set working directory
WORKDIR /app
# Copy package files
COPY package*.json ./
# Install dependencies
RUN npm ci --silent
# Copy source code
COPY . .
# Build the app
RUN npm run build
# Stage 2: Serve the app with Nginx
FROM nginx:alpine
# Copy built app from builder stage
COPY --from=builder /app/build /usr/share/nginx/html
# Copy custom nginx config (optional)
COPY nginx.conf /etc/nginx/conf.d/default.conf
# Expose port 80
EXPOSE 80
# Start Nginx
CMD ["nginx", "-g", "daemon off;"]