Skip to content
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
33 lines (20 sloc) 464 Bytes
FROM node:alpine
# create directory
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
# install dependencies
COPY package.json package.json
COPY yarn.lock yarn.lock
RUN npm install -s --global yarn
RUN yarn install
# build source
COPY source source
RUN yarn run build
# install production dependencies
RUN rm -r source/ node_modules/
RUN yarn install --production
RUN npm remove --global yarn
# expose ports
# run
CMD ["node", "build/server"]
You can’t perform that action at this time.