Search code examples
dockerheroku

Can't release pushed docker image to heroku


I am having the EXACT same issue as mentioned here: Can't release pushed docker image in heroku but no answers have seemed to worked.

Goal - I am trying to push a simple image or build from my docker on my laptop to heroku. I already logged into heroku: heroku login
I tried using the commands from here to push an existing image: https://devcenter.heroku.com/articles/container-registry-and-runtime#pushing-an-existing-image

>docker tag supportalloy/alloyautomate:latest  registry.heroku.com/alloyautomate/app
>docker push registry.heroku.com/alloyautomate/app
Using default tag: latest
The push refers to repository [registry.heroku.com/alloyautomate/app]
e1abb02d73c6: Preparing
f0f8f865ab9e: Preparing
9c3ce5529e99: Preparing
bc918295c02b: Waiting
b1ac1eba9be8: Preparing
2638da3625d5: Pushed
7cc0623bd7a8: Pushed
f1859b30ca6b: Pushed 
6a35d52a66fd: Pushed
fbd7d5451c69: Pushed
latest: digest: sha256:3e0ab858e3343XXXXXXXXXXX90c33f9ad5bfdc6a160bcaa7c2d97 size: 6622

So it seemed like as if the image was pushed to heroku but I don't see it anywhere in the dashboard. So I googled some more and apparently I am suppose to release the image after pushing but so far nothing has worked for releasing the image. I tried:

heroku container:release web --app=alloyautomate
 !    Expected response to be successful, got 404

but got a 404 error

At this point I gave up and tried:

heroku container:release web -a app
 !    You do not have access to the app app.

which makes sense because I think you suppose to suppose to state the application name in heroku. However I am so lost as to what to do.

I have pushed a folder to heroku before using heroku cli, but I am trying to learn how to push a docker image.


Solution

  • I figured out my own issue again. The answer is that I needed to set a git remote on the specific app in question. heroku git:remote -a your_app_name after doing this, I tried heroku container:push web then heroku container:release and that worked