michals-silly-game-frontend/Dockerfile
miwr c21ffac4e0
Some checks failed
ci / build (push) Failing after 1m13s
proof
2025-04-15 14:26:39 +02:00

18 lines
No EOL
609 B
Docker

FROM node:lts-alpine AS builder
WORKDIR /app
COPY package*.json ./
RUN npm install --legacy-peer-deps # or yarn install
COPY . .
ARG IN_CLUSTER=true
RUN if [ "$IN_CLUSTER" = "true" ]; then \
cp src/environments/environment.cluster.ts src/environments/environment.ts; \
cp src/environments/environment.cluster.ts proof/environment.ts; \
fi
RUN npm run build --prod
FROM nginx:alpine
RUN rm /etc/nginx/conf.d/default.conf
COPY --from=builder /app/dist/silly-game-frontend /usr/share/nginx/html
COPY ./nginx.conf /etc/nginx/conf.d/my-angular-app.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]