Skip to content

watcharap0n/fastapi-docker-heroku

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Deploying a Dockerized FastAPI Application to Heroku

Directory

-> Directory
/root - app/
|-- server
|   |-- main.py
|-- .env
|-- .gitignore
|-- docker-compose.yml
|-- Dockerfile
|-- heroku.yml
|-- README.md
|-- requirements.txt

Login Heroku

$ heroku login

Build container & run for a service testing

This allows you to test your app locally. It’s hosted on http://localhost:85.

$ docker compose up

Create your application on Heroku

$ heroku create [your-app]

Deploy Application to Heroku

$ heroku container:push web -a [your-app]
$ heroku container:relese web -a [your-app]

Now success to deployment

Check your url: [https://your-app.herokuapp.com]

$ heroku open -a [your-app]

Releases

No releases published

Packages

No packages published