sosso / flask-sqlalchemy-heroku

Easily edit and deploy a Flask based app with sqlalchemy and postgresql on Heroku with this boilerplate

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Boilerplate for a flask based app with sqlalchemy and postgresql, deploy easily on heroku

Deploy

dependencies used in the virtual_env :

flask flask-sqlalchemy flask-script gunicorn psycopg2 flask-marshmallow requests python-dotenv flask-bcrypt marshmallow-sqlalchemy python-dotenv

Install the app and environment :

git clone https://github.com/gmolveau/flask-sqlalchemy-heroku
cd flask-sqlalchemy-heroku
virtualenv venv -p python3
source venv/bin/activate
pip3 install -r requirements.txt

Test the app :

# if the heroku toolbelt is installed
heroku local

# else if on unix
gunicorn wsgi:app

# else if on windows
python3 wsgi.py

Test the stack (with docker) :

docker-compose up --build

# or in the background with
docker-compose up --build -d

Schedule a task for free every 10 minutes, every hour, or every day with heroku-scheduler :

Scheduler

About

Easily edit and deploy a Flask based app with sqlalchemy and postgresql on Heroku with this boilerplate

License:MIT License


Languages

Language:Python 92.5%Language:Dockerfile 3.7%Language:HTML 2.1%Language:Shell 1.7%