cd "Path to wherever you want to clone it."
git clone <repo-url>
cd brainlylab-backendpython -m venv venv.\venv\Scripts\activateTerminal shows:
(venv)
pip install -r requirements.txtThis installs Django and other required libraries.
Copy the example environment file:
copy .env.example .envExample:
DB_NAME=brainlylab
DB_USER=postgres
DB_PASSWORD=your_postgres_password
DB_HOST=localhost
DB_PORT=5432
Install:
- PostgreSQL server
- pgAdmin
PostgreSQL runs the database.
pgAdmin is the GUI tool to manage it.
Inside pgAdmin:
Servers
→ PostgreSQL
→ Databases
→ Create Database
Database name:
brainlylab
This creates tables in the database.
python manage.py migrateYou saw many lines like:
Applying auth.0001_initial... OK
python manage.py runserverServer runs at:
http://127.0.0.1:8000
GitHub Repo
↓
Virtual Environment
↓
Django Backend
↓
PostgreSQL Database
↓
Local Server (127.0.0.1:8000)
If you open the project again, you only need:
cd brainlylab-backend
.\venv\Scripts\activate
python manage.py runserver