ClientSphere is a Django + PostgreSQL CRM app with a modernized React-powered UI layer and MFA-protected access.
| Layer | Technology |
|---|---|
| Frontend | React 18 (client-rendered in Django templates), Bootstrap 5, custom CSS |
| Backend | Django 5.x |
| Database | PostgreSQL |
| Auth | django-two-factor-auth + django-otp (TOTP + backup tokens) |
| Environment | Python venv + .env |
- User registration and secure login flow
- MFA setup and verification (authenticator app + backup codes)
- OTP-verified access to client records
- Responsive modern UI with preserved brand color scheme
- Django admin support (MFA patched)
git clone https://github.com/EliMeed/ClientSphere.git
cd ClientSphere
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txtCreate .env in project root:
DJANGO_SECRET_KEY=replace-with-a-strong-random-key
DJANGO_DEBUG=True
DJANGO_ALLOWED_HOSTS=127.0.0.1,localhost
DB_NAME=managers
DB_USER=appuser
DB_PASSWORD=replace-with-db-password
DB_HOST=127.0.0.1
DB_PORT=5432
DJANGO_SECURE_SSL_REDIRECT=FalseYou can start from:
cp .env.example .envMake sure PostgreSQL is running and credentials in .env are valid.
Example setup:
sudo -u postgres psql -c "CREATE USER appuser WITH PASSWORD 'your_password';"
sudo -u postgres psql -c "CREATE DATABASE managers OWNER appuser;"python manage.py migrate
python manage.py createsuperuser
python manage.py runserver- Login:
/account/login/ - MFA setup:
/account/two_factor/setup/ - Backup tokens:
/account/two_factor/backup/tokens/
- Do not commit
.env - Use strong secrets/passwords in non-local environments
- Set
DJANGO_DEBUG=Falsein production - Configure production hostnames in
DJANGO_ALLOWED_HOSTS