Herokuへのdeployについて
前回一度やってみたがなかなかうまくいかなったので再度ここへつまづいた箇所をまとめます。
heroku addons:create heroku-postgresql:hobby-dev
› Error: Missing required flag:
› -a, --app APP app to run command against
› See more help with --help
そもそもherokuのプラグインが入っていない?
heroku plugins
no plugins installed
とりあえずインストールしてみます
heroku plugins:install heroku-accounts
Installing plugin heroku-accounts... installed v1.1.7
インストールできました。
heroku plugins
heroku-accounts 1.1.7
どうもリモートにherokuのリポジトリが入っていないみたい。
git remote -v
origin https://github.com/jacoloves/oyotoru_kun.git (fetch)
origin https://github.com/jacoloves/oyotoru_kun.git (push)
追加してみます。
git remote add heroku https://git.heroku.com/oyotoru-kun.git
追加されました。
git remote -v
heroku https://git.heroku.com/oyotoru-kun.git (fetch)
heroku https://git.heroku.com/oyotoru-kun.git (push)
origin https://github.com/jacoloves/oyotoru_kun.git (fetch)
origin https://github.com/jacoloves/oyotoru_kun.git (push)
これでheroku run bashができたのでスタートに立てました汗
heroku run bash
Running bash on ⬢ oyotoru-kun... up, run.5730 (Free)
モジュールはデプロイできてたみたいです。
postgreDBも増設できました。
heroku addons:create heroku-postgresql:hobby-dev
Creating heroku-postgresql:hobby-dev on ⬢ oyotoru-kun... free
Database has been created and is available
! This database is empty. If upgrading, you can transfer
! data from another database with pg:copy
Created postgresql-shallow-20555 as DATABASE_URL
Use heroku addons:docs heroku-postgresql to view documentation
今回はここまで