Skip to content
This repository has been archived by the owner on Jul 26, 2022. It is now read-only.

Commit

Permalink
chore(Dockerfile): install with --production, rejigger layers (#23)
Browse files Browse the repository at this point in the history
  • Loading branch information
silasbw committed Feb 20, 2019
1 parent 5cffe97 commit 007c7d0
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions Dockerfile
@@ -1,18 +1,15 @@
FROM node:10.15.1-alpine

# Set ENV vars
ENV NODE_ENV production
ENV NPM_CONFIG_LOGLEVEL info

RUN npm install npm@6.4.1 -g

# Setup source directory
RUN mkdir /app
WORKDIR /app
COPY package.json package-lock.json /app/

# npm install
ARG skip_install=
RUN npm install npm@6.4.1 -g
RUN if [ -z "$skip_install" ]; then npm ci; fi
RUN npm ci --production

# Copy app to source directory
COPY . /app
Expand Down

0 comments on commit 007c7d0

Please sign in to comment.