-
Install Python 3.10. pyenv can help with switching among different Python versions.
-
Install poetry and dependencies:
pip install poetry
poetry install
- Run tests, launch the app:
poetry shell
make test
make flask
-
Install Python 3.10. Make sure
python
is added toPATH
. You can check this by navigating toSystem (Control Panel)
->Advanced system settings
->Environment Variables
->System Variables
->PATH
->Edit
. -
Install Chocolatey.
-
Install GNU make:
choco install make
- Install poetry and dependencies:
pip install poetry
poetry install
- Run tests, launch the app:
poetry shell
make test
make flask-win
Thanks to @Plintus-bit for making the awesome logo!
If you are using code, press Ctrl+Shift+P
in order to activate poetry virtual environment after installation, or just type poetry shell
in the terminal. Run unit tests via make test
, run the app via make flask
, run the linter as make lint
, run linter fixes via make fix
. If you prefer to use containers, there are make image
and make container
scripts that will build a Docker image and run the app inside that image. A sample run script for production might look like as follows:
# Use the following if you'd like to seed the database:
# export SEED=1 && sh start.sh
# Don't forget to: unset SEED
export CONFIG_PATH=/home/app/webapp/config
. /home/app/.cache/pypoetry/virtualenvs/app-_h2eKbNq-py3.10/bin/activate
cd src/webapp
waitress-serve --port 8080 --call 'app:create_app'