Created
July 14, 2017 01:49
-
-
Save mattc41190/d9fab6ce49f65118534c26acf6d2543b to your computer and use it in GitHub Desktop.
Simple Server 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
# Choose a base image | |
FROM node:8.1.3 | |
# Make a landing zone for our app | |
RUN mkdir app | |
# Copy the contents of the pwd/cwd into the image's /app directory | |
COPY . /app | |
# Go into the /app dir and run npm install | |
RUN cd /app; npm install | |
# Choose some ports to expose to the host machine | |
EXPOSE 3344 80 | |
# Choose a dir from which to call commands | |
WORKDIR "/app" | |
# Choose a command for the image to do at run time | |
ENTRYPOINT ["node", "server.js"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment