- Docker 🐳
- cURL or something that can make a patch HTTP request
- Heroku Account
- Free time. 😁
docker-compose up --build
- Login to heroku
- Click on this
- Enter your app name
We will call the app name <APP_NAME> from this point
docker tag streamlit-docker registry.heroku.com/<APP_NAME>/web
replace "streamlit-docker" to your new image name if you have changed image name in docker-compose.yml
- Login to heroku
- Go to account settings
- Scroll down click on Reveal and Get your Oauth token
We will call it <API_KEY> from this point
docker inspect --format="{{.Id}}" registry.heroku.com/<APP_NAME>/web
Psst. Its not IMAGE_NAME !
It looks something like this
docker login --username=_ --password=<API_KEY> registry.heroku.com
Yes the username is underscore !
docker push registry.heroku.com/<APP_NAME>/web
curl --netrc -X PATCH https://api.heroku.com/apps/<APP_NAME>/formation \
-d '{
"updates": [
{
"type": "web",
"docker_image": "<IMAGE_ID>"
}
]
}' \
-H "Content-Type: application/json" \
-H "Accept: application/vnd.heroku+json; version=3.docker-releases"\
-H "Authorization: Bearer <API_KEY>"