Kick-starter to your REST application.
- Fill the .env file with the following values, they might need adjustment.
DEBUG=<BOOLEAN> # Dev: True SECRET_KEY=<TOKEN> # Dev: a1b2c3d4e5f6g7h8i9j10k11l12m13n14o15p16q SQLALCHEMY_DATABASE_URI=<SQLITE> # Dev: sqlite:///db.sqlite3
- Create a virtual environment: -
python -m venv venv
- Activate: -
- Windows:
venv\Scripts\activate - Unix-like:
. venv\bin\activate
- Windows:
- Install dependencies: -
pip install . -e '.[all]'
- Set environment variable: -
- Windows:
SET FLASK_APP=app.wsgi - Unix-like:
export FLASK_APP=app.wsgi
- Windows:
- Create a new user: -
flask manage createsuperuser
- Run: -
flask run --debug
- Create a virtual environment: -
python -m venv venv
- Activate: -
- Windows:
venv\Scripts\activate - Unix-like:
. venv\bin\activate
- Windows:
- Install dependencies: -
pip install -e '.[deployment]' - Set environment variable: -
- Windows:
SET FLASK_APP=app.wsgi - Unix-like:
export FLASK_APP=app.wsgi
- Windows:
- Create a new user: -
flask manage createsuperuser
- Run: -
gunicorn -b 0.0.0.0:8000 app.wsgi:application -w 4 -t 9