Last active
October 15, 2017 23:58
-
-
Save jkinkead/4580c22561dc804ef8f22fed235782b2 to your computer and use it in GitHub Desktop.
Naive Dockerfile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You should always specify a full version here to ensure all of your developers | |
# are running the same version of Node. | |
FROM node:7.8.0 | |
# The base node image sets a very verbose log level. | |
ENV NPM_CONFIG_LOGLEVEL warn | |
# Copy all local files into the image. | |
COPY . . | |
# Build for production. | |
RUN npm run build --production | |
# Install `serve` to run the application. | |
RUN npm install -g serve | |
# Set the command to start the node server. | |
CMD serve -s build | |
# Tell Docker about the port we'll run on. | |
EXPOSE 5000 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment