You can host Flask apps for free on Heroku.
Check this insta-analytics web-app.
In the previous blog, we learnt to host this app locally. It’s time to publish it on Heroku to make it globally accessible.
Some of the prerequisites are: Git repository & Heroku account.
The new files that would be needed before publishing it on Heroku:
- Procfile (Easiest to create it using VS Code)
- Requirements.txt (contains all the python modules required by the app)
The files need to be organized as shown here:
You can refer the git repos: Piyush-Kulkarni or Vaani’s git repo here.
Once you create the Procfile in VS code, it looks as shown here:
Steps to deploy on Heroku:
- Sign up.
- Choose deployment method: Github
- Deploy manually
You will have the URL to your web-app, once the deployment is complete.
Writers- Piyush Kulkarni, Vaani Bansal.