Cheatography
https://cheatography.com
Utils
heroku version |
Version |
heroku login |
Login |
heroku create [appName] |
Create app |
heroku rename [newName] |
Rename app |
Server
heroky logs -t |
Show logs |
heroku config:set PORT=3000 |
Create env variable |
heroku config |
Show env |
heroku run bash |
Runs bash in an off-dyno |
heroku open graphql |
Open server webpage to /graphql |
heroku ps:scale web=0 |
Stop all the dynos |
heroku ps:scale web=1 |
Start a dyno |
heroku restart |
Restart the app |
Database
heroku addons:create heroku-postgresql:hobby-dev --version=12 |
Create an addon |
heroku addons:docs heroku-postgresql |
Addon's documentation |
heroku pg:wait |
Wait pg is running |
cat database/init_database.sql | heroku pg:psql |
Init Database |
heroku pg:info |
Info Database usage |
heroku pg:psql
\dt+ |
Show tables |
SELECT * FROM "User"; |
Show all users |
SELECT * FROM user; |
Show postgre user |
GRANT [userName] to postgres |
Grant userName to postgres (not used) |
Git
heroku git:remote -a [appName] |
App heroku remote to project |
git subtree push --prefix my-dir heroku main |
Push a specific folder to heroku main branch |
git subtree split -P my-dir -b my-dir-branch |
Creates a new branch with only the specified folder |
Frontend
HOSTNAME=[appName].herokyapp.com |
Set HOSTNAME in front |
|
Created By
Metadata
Comments
No comments yet. Add yours below!
Add a Comment