- install pipenv
$ sudo -H pip3 install -U pipenv
- clone the repo & cd into it
- install dependencies
$ pipenv install
- Copy & rename .env.example file to .env
- Set the database credentials inside .env
- Make DB Migrations -
$ pipenv run python manage.py db init
$ pipenv run python manage.py db migrate
$ pipenv run python manage.py db upgrade
- run the app
$ pipenv run flask run
- or
$ pipenv run flask run --cert=adhoc
- or
$ pipenv run gunicorn -b 0.0.0.0:5000 --access-logfile - --reload "app:create_app()"
- generate requirements.txt
$ pipenv lock -r > requirements.txt
- Make sure Docker & Docker-Compose are installed
- run
$ docker-compose up -d
- exec into the app container and make DB migrations
$ docker exec -it CONTAINER_ID bash
- see app logs
$ docker logs -f CONTAINER_ID
- clean up
$ docker-compose down -v