Skip to content

Instantly share code, notes, and snippets.

@NathBabs
Created October 5, 2021 22:06
Show Gist options
  • Save NathBabs/f83446c94834ef13c2a7e9738020e196 to your computer and use it in GitHub Desktop.
Save NathBabs/f83446c94834ef13c2a7e9738020e196 to your computer and use it in GitHub Desktop.
Deploy container to Heroku
Deploy to Heroku in Container
login to heroku
heroku container:login
create an app for containers
heroku create
check image names
docker image ls
tag the image for heroku
docker tag imagename registry.heroku.com/heroku-app-name-created-in-prev-step/web
push the tagged image to heroku's registry
docker push registry.heroku.com/heroku-app-name-created-in-penultimate-step/web
release code of app
heroku container:release web -a heroku-app-name-created-in-antepenultimate-step
open sesame
heroku open
Remove EXPOSE 9000 port from your Dockerfile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment