Pregunta

I have remotes to two heroku apps, one for staging and one for production. I am encountering a strange permission denied error when I try to target one of the apps. For example, if I run:

heroku logs --app staging

I get back:

!    You do not have access to the app staging.

However, if I simply change the command to:

heroku logs --remote staging

it works fine. Of course this isn't a huge inconvenience, but I would like to be able to use the --app extension without permission issue. If anyone has encountered this before, or has any ideas as to why this may be, please let me know :).

Thanks!

¿Fue útil?

Solución

These two options use entirely different mechanisms to lookup the Heroku app by 1) git remote name 2) heroku app name.

When you say --app staging you are looking up an app called staging which you do not own, and getting a permission denied.

When you use the --remote staging you are looking up the app attached to your git remote called staging and it works.

The right way to use --app is with --app your-app-name, since staging is not your app.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top