Skip to content

Commit

Permalink
Adding argument to Dockerfile for argument since NODE_ENV not set cau…
Browse files Browse the repository at this point in the history
…ses issues.
  • Loading branch information
BuckinghamAJ committed Aug 14, 2023
1 parent fb3b7bd commit a2f53d1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,13 @@ RUN touch winston.log.json

RUN npm cache clean --force

# Get environment argument passed in
ARG environment
ARG default_environment=development

# Set NODE_ENV environment variable
ENV NODE_ENV=${environment:-$default_environment}

# Check environment and install dependencies
# Note: When the NODE_ENV environment variable is set to 'production' npm
# will not install modules listed in devDependencies
Expand Down

0 comments on commit a2f53d1

Please sign in to comment.