Fork this repo to your GitHub account, then clone it.
git clone https://github.com/your-github-username/CI_CD_server_flask
cd into the project directory, set up environment variables and bootstrap the project:
cd CI_CD_server_flask
export MY_SECRET_KEY='something-really-secret'
export FLASK_APP=autoapp.py
export FLASK_DEBUG=1
python3 -m venv venv
source venv/bin/activate
pip install -r requirements/dev.txt
Run the following commands to create your app's database tables and perform the initial migration:
flask db init
flask db migrate
flask db upgrade
Run the tests locally:
flask test
Run server
flask run
In your production environment, make sure the FLASK_DEBUG
environment variable is unset or is set to 0
, so that ProdConfig
is used.
- Python (>=3.7)
- git
- heroku account
This repository is a modification of gothinkster's flask-realworld-example-app: https://github.com/gothinkster/flask-realworld-example-app