Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
qiushihao authored Jul 25, 2023
1 parent 4f7b47d commit e788a18
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
FROM node:latest

WORKDIR /usr/src/app

# build stage
FROM node:lts-alpine as build-stage
WORKDIR /app
COPY package*.json ./

RUN npm ci

RUN npm install
COPY . .
RUN npm run build

# production stage
FROM nginx:stable-alpine as production-stage
COPY --from=build-stage /app/dist /usr/share/nginx/html
EXPOSE 80

CMD ["npm", "run", "dev", "--", "--port", "80"]
CMD ["nginx", "-g", "daemon off;"]

0 comments on commit e788a18

Please sign in to comment.