Losely based on a free codecamp page
You can find the code for that here
I've modified the structure a little bit "lot" to fit our needs.
To run using gunicorn
venv/bin/gunicorn app
To use one of the configs
venv/bin/gunicorn --config gunicorn_config.py app
To start on a custom port (say from docker :P). Note command line takes precidence over config file.
venv/bin/gunicorn --config gunicorn_config.py --bind 0.0.0.0:10086 app
To run using flask
python3 manage.py run
To run testing scripts (not implemented by default)
python3 manage.py test
Using the manage.py framework you can do things like autoinit db connections and the like.