Files
doneit-web/dockerfile
T

26 lines
552 B
Docker
Raw Normal View History

2026-04-14 09:49:29 +01:00
# ---------- Build Stage ----------
FROM node:16-alpine AS build
2022-06-02 16:11:57 +01:00
2026-04-14 09:49:29 +01:00
WORKDIR /app
# Install Ionic CLI (optional but safe)
RUN npm install -g @ionic/cli@6 @angular/cli@12
COPY package*.json ./
RUN npm install
COPY . .
# Build production app
RUN ionic build --prod
# ---------- Run Stage ----------
FROM nginx:alpine
# Copy build output to nginx
COPY --from=build /app/www /usr/share/nginx/html
# Expose port
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]