After converting to Docker images, I have extra dynos that I'm unable to scale down or stop.
- I previously built a slug-based app with the process types
- I switched to Docker images, and now use containers named
- I now have a
workerdyno that remains on my app, but attempts to stop or scale it fail with a "Couldn't find that process type" error
When pushing and switching to Docker images, dyno management changes in ways that are incompatible with standard Heroku-built slugs. If your released container process type names differ from the names of your process types previously specified in your
Procfile, your previous process types may continue to attempt to start and crash repeatedly, continuing to accrue billing charges.
In order to resolve this, you need to make Docker "aware" of the previous process type(s) in order to be able to scale them down.
Using the previous process types as an example, you want to run
background_jobs, so the
worker group needs to be scaled down. To resolve this situation you should run:
heroku container:push worker heroku container:release worker heroku ps:scale worker=1 heroku ps:scale worker=0
All 4 steps are important, you must scale the group up, and then down in order to stop them.
Once completed, the dynos in these process types should no longer be attempting to start, nor show up in
heroku ps, and the its group will be listed as scaled to zero on the Heroku Dashboard.