Created
October 26, 2016 20:59
-
-
Save sskoopa/333b098035e66639f3a947459f095ac9 to your computer and use it in GitHub Desktop.
Dockerfile for using google-cloud (or any native module) and sharing app with Mac local
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
#alpine-node is a super small distro with just the minimum to run | |
FROM mhart/alpine-node:6 | |
WORKDIR /app | |
#allow local code to mount into this directory | |
VOLUME /app | |
#move all native plugins up to -g installs and link them one level above the app | |
RUN npm install -g google-cloud && cd / && npm link google-cloud && cd /app | |
#serve on port 8080 | |
EXPOSE 8080 | |
#call npm start on whatever directory you mounted to /app | |
CMD npm start |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment