Skip to content

Instantly share code, notes, and snippets.

@michealbenedict
Created July 18, 2012 02:50
Show Gist options
  • Save michealbenedict/3133794 to your computer and use it in GitHub Desktop.
Save michealbenedict/3133794 to your computer and use it in GitHub Desktop.
Node.js App
app:~$ nodeaku deploy
{
"name": "helloworld",
"version": "0.0.1",
"dependencies": {
"nodeaku": "git+https://git.twitter.biz/nodeaku"
},
"scripts": {
"start": "node <startfile>"
},
"nodeaku": {
"user": "<username>",
"cpu": "1.0",
"ram": "512",
"disk": "512",
"cluster": "smf1"
}
}
var http = require('http');
if ( process.env.NODE_ENV === 'production' ) { console.log('env var is set to production'); }
http.createServer(function (req, res) {
res.writeHead(200, {'Content-Type': 'text/plain'});
res.end('Hello World\n');
}).listen(process.env.NODE_PORT);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment