- Python 3.10+
python -m venv venv
venv\Scripts\activate
. venv/bin/activate
pip install -r requirements.txt
OKNESSET_DB_USER="USER NAME" OKNESSET_DB_PASSWORD="PASSWORD" OKNESSET_DB_HOST="HOST" OKNESSET_DB_PORT="PORT" OKNESSET_DB_NAME="postgres"
uvicorn main:app --reload
This is the same way the app is run in production.
Create the .env
file as described above.
Build:
docker build -t open-knesset-backend .
Run:
docker run --env-file .env -p 8000:80 open-knesset-backend