-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
33 lines (33 loc) · 1.23 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# -----------------------------------------------------------------
# Dockerfile for building the blobfishes project
# -----------------------------------------------------------------
FROM node:14.17.3-alpine
#
# -----------------------------------------------------------------
# Default template for running Node.js apps in production mode
# -----------------------------------------------------------------
# ENV NODE_ENV=production
# WORKDIR /usr/src/app
# COPY ["package.json", "package-lock.json*", "npm-shrinkwrap.json*", "./"]
# RUN npm install --production --silent && mv node_modules ../
# COPY . .
# EXPOSE 3000
# CMD ["npm", "start"]
# -----------------------------------------------------------------
#
# -----------------------------------------------------------------
# Run Node.js app in development mode
# -----------------------------------------------------------------
# ENV NODE_ENV=production
WORKDIR /usr/src/app
COPY ["package.json", "package-lock.json*", "npm-shrinkwrap.json*", "./"]
# RUN ls -laR
RUN npm install --silent
COPY . .
RUN npm run build:server
# RUN ls -la
# RUN ls -laR dist/
CMD ["npm", "run", "serve:prod"]
# -----------------------------------------------------------------
#
# EOF