2021-05-05 01:08:58 +00:00
|
|
|
FROM node:latest
|
|
|
|
|
|
|
|
# set working directory
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
# add `/app/node_modules/.bin` to $PATH
|
|
|
|
ENV PATH /app/node_modules/.bin:$PATH
|
|
|
|
|
|
|
|
# install app dependencies
|
|
|
|
COPY package.json ./
|
|
|
|
COPY package-lock.json ./
|
|
|
|
|
2021-06-30 00:14:42 +00:00
|
|
|
RUN npm install
|
2021-05-05 01:08:58 +00:00
|
|
|
|
|
|
|
# add app
|
|
|
|
COPY . ./
|
|
|
|
|
|
|
|
# start app
|
|
|
|
CMD ["npm", "start"]
|