Shallie/Dockerfile

15 lines
289 B
Docker
Raw Normal View History

2024-09-11 06:08:09 +00:00
FROM node:18-alpine
2022-07-23 20:52:23 +00:00
# install dependencies
WORKDIR /app
COPY . .
2024-03-12 17:06:34 +00:00
RUN npm install
RUN npm run build
2022-07-23 22:04:56 +00:00
FROM node:16-alpine
2022-07-23 20:52:23 +00:00
WORKDIR /app
2022-07-23 22:04:56 +00:00
COPY --from=0 /app/build /app
COPY --from=0 /app/package.json /app
COPY --from=0 /app/node_modules /app/node_modules
2022-07-23 20:52:23 +00:00
EXPOSE 3000
2022-07-23 22:04:56 +00:00
CMD ["node","./index.js"]