Skip to content

Instantly share code, notes, and snippets.

@JohnProg
Created April 7, 2014 04:52
Show Gist options
  • Save JohnProg/307eb3993c24b2b4c20a to your computer and use it in GitHub Desktop.
Save JohnProg/307eb3993c24b2b4c20a to your computer and use it in GitHub Desktop.
$ heroku login
$ heroku create myapp
// modify in Gruntfile.js change the tasks in the list to your production tasks
grunt.registerTask('heroku',
['compass:dist', 'autoprefixer', 'imagemin']);
touch app.js
nano app.js
//write this
var express = require('express');
var port = process.env.PORT || 3000;
var app = express();
app.use(express.static(__dirname + ‘/app’));
app.listen(port);
$ npm install express -save
touch Procfile
nano Procfile
//write this
web: node app.js
//push to heroku
git init
git add .
git commit -m "init"
heroku git:remote -a myapp
git push heroku master
heroku ps:scale web=1
//for then:
$ git add .
$ git commit -m"Describe here your changes"
$ git push heroku master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment