Last active
January 16, 2016 16:59
-
-
Save chiefy/c914b3d8f94ce08a01b2 to your computer and use it in GitHub Desktop.
examples for a blog post
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
| node_modules | |
| .git |
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
| node_modules |
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
| code: | |
| build: . | |
| app: | |
| image: quay.io/oddnetworks/alpine-nodejs:4.2.3 | |
| volumes_from: | |
| - code | |
| ports: | |
| - "8080:3000" | |
| working_dir: /app | |
| command: /bin/ash -c "npm install --production && npm run start" |
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
| code: | |
| build: . | |
| app: | |
| image: quay.io/oddnetworks/alpine-nodejs:4.2.2 | |
| volumes_from: | |
| - code | |
| ports: | |
| - "8080:3000" | |
| working_dir: /app | |
| command: /bin/ash -c "npm install --production && npm run start" |
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
| FROM tianon/true | |
| ADD . /app | |
| VOLUME /app |
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
| var express = require('express'); | |
| var app = express(); | |
| app.get('/', function (req, res) { | |
| res.send('I am running nodejs version: ' + process.versions.node ); | |
| }); | |
| app.listen(3000, function () { | |
| console.log('Example app listening on port 3000!'); | |
| }); |
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
| { | |
| "name": "sample", | |
| "version": "1.0.0", | |
| "main": "index.js", | |
| "scripts": { | |
| "start": "node /app/index.js" | |
| }, | |
| "dependencies": { | |
| "express": "^4.13.3" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment