Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

README.md

PyMatcha

Python Matcha Dating Website

Installation

Create a virtual environnement

python3 -m venv venv

Activate the virtual environnement

source venv/bin/activate

Install the requirements

pip install -r requirements.txt

Dev install

Install pre-commit

pip install pre-commit
pre-commit install

Running the server

TODO: Update the var list

Key Value Comment
FLASK_ENV Either prod or dev If this variable is set to dev, then no need to supply FLASK_DEBUG and FLASK_SECRET_KEY
FLASK_DEBUG True or False
FLASK_SECRET_KEY A secret key to encrypt cookies
DB_USER Database user
DB_PASSWORD Database password
DB_HOST Database host must be pymatchadb.cvesmjtn6kz7.eu-west-3.rds.amazonaws.com for production or pymatchadb-tests.cvesmjtn6kz7.eu-west-3.rds.amazonaws.com for tests
CI Is the server in a CI environment Must be set to 0 if on a prod environement. If set to 1, will erase the test DB.
python app.py

Running tests

TODO: Explain how to setup tests on postman with the collection and the server

Flake8

flake8
export FLASK_DEBUG=1 && export FLASK_SECRET_KEY=ThisIsADevelopmentKey && export DB_USER=pymatcharoot && export DB_PASSWORD=PASSWORD && export DB_HOST='pymatchadb-tests.cvesmjtn6kz7.eu-west-3.rds.amazonaws.com' && export CI=1 && python -m pytest

TODO: Setup postman cli in CI