0

Below is my app.json:

{
    "environments": {
      "review": {
        "addons": [
            "heroku-postgresql:in-dyno"
        ],
        "scripts": {
            "postdeploy": "php artisan migrate --seed"
        }
      }
    }
  }

In my understanding, a review app with such configuration should be starting with Postgres DB and run my script afterwards; the app starts, yet no Postgres is attached and I don't see any errors in Build log nor Application Logs.

How should my app.json be structured to do what I want?

  • Does the app work? Your question is a bit unclear on that front. If it doesn't, it's possible that php artisan migrate --seed needs a --force parameter to bypass the "your app is in production, continue y/n?" prompt. – ceejayoz Jun 11 '19 at 12:49
  • The app does work. Added clarification on that part – eithed Jun 11 '19 at 13:51
  • OK, so your app.json is doing what you told it to do, and your app works. What's the issue? – ceejayoz Jun 11 '19 at 13:52
  • yet no Postgres is attached, In my understanding, a review app with such configuration should be starting with Postgres DB – eithed Jun 11 '19 at 13:53
1

in-dyno means a Postgres instance won't be attached - it'll be directly within the dyno itself. Not seeing errors in the build log would, thus, be normal.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.