Last active
February 22, 2018 21:50
-
-
Save josephhhhh/3cae85d2dd9eb1ada67eda3e556828fd to your computer and use it in GitHub Desktop.
node app deploy heroku bash script
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
| #!/bin/bash | |
| # usage: ./deploy.sh <github_repo> <app_name> | |
| # perform local testing | |
| repo=$1 | |
| git clone $repo _repo | |
| cd _repo | |
| npm install | |
| npm test | |
| # start deploying | |
| app=$2 | |
| heroku create $app; | |
| git remote set-url heroku https://git.heroku.com/${app}.git | |
| git push heroku master; | |
| heroku ps:scale web=1; | |
| heroku open; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment