Skip to content

Instantly share code, notes, and snippets.

@ravshansbox
Last active September 12, 2023 12:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ravshansbox/ec63b350c5554269985c59e7d1604b73 to your computer and use it in GitHub Desktop.
Save ravshansbox/ec63b350c5554269985c59e7d1604b73 to your computer and use it in GitHub Desktop.
FROM node:18-alpine AS build
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci
COPY . ./
RUN npm run build
RUN find ./dist -type f | xargs gzip -k
FROM nginx:1-alpine
COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY --from=build /app/dist /usr/share/nginx/html
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment