Skip to content

Latest commit

 

History

History
78 lines (51 loc) · 1.91 KB

File metadata and controls

78 lines (51 loc) · 1.91 KB

⚙️ Set up and run BACKEND

In this section we will cover how to set up the backend of the application.

🛠 Set up the proyect

1. Enter backend directory

cd Backend/

2. Launch Backend dependencies using Docker

This will launch all required dependencies such as MongoDB database for local backend development.

cd Backend/docker/;
./build_and_up_dev_backend.sh;
  • Learn more about other Docker configurations for the application in Docker docs.

3. Get or create .env file under `Backend/

A development ready environment files is provided at Backend/docker/. The environment files has to be placed under Backend/ folder and should be named .env. It can be done using the following command:

cd Backend/docker/;
cp env/dev.env ../.env;

4. Install the virtual environment and dependencies

🪟 Windows

cd Backend/;
python -m venv venv;
venv/Scripts/activate;
pip install -r requirements.txt;
pip install -r requirements-dev.txt;
pip install -r requirements-test.txt;

🐧 Linux

cd Backend/ &&
python3.12 -m venv venv &&
source venv/bin/activate &&
pip install -r requirements.txt &&
pip install -r requirements-dev.txt &&
pip install -r requirements-test.txt

5. Run the app:

Standar with hot reload

This will automatically reload the app if changes are made.

python -m app

Debug

Launch the app in debug mode using DEBUG Backend app at VSCODE debug section. Breakpoints selected in code will be triggered.