Last active
January 14, 2017 10:35
-
-
Save kikill95/12a6301244e67678a0475f8abd640a2a to your computer and use it in GitHub Desktop.
Heroku
This file contains 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
heroku login | |
heroku create | |
// heroku config:set NPM_CONFIG_PRODUCTION=false | |
git push heroku master | |
heroku open |
This file contains 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 app = require('express')(); | |
var http = require('http').Server(app); | |
app.get('/', function(req, res) { | |
res.sendFile(__dirname + '/dist/index.html'); | |
}); | |
http.listen(process.env.PORT || 3000, function() { | |
console.log('Listening on:' + (process.env.PORT || 3000)); | |
}); |
This file contains 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": "mockupdec", | |
"version": "0.0.1", | |
"scripts": { | |
"postinstall": "node_modules/.bin/gulp" | |
}, | |
"license": "ISC", | |
"dependencies": { | |
"express": "^4.14.0" | |
} | |
} |
This file contains 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
web: node index.js |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment