BackendGetting Started
Running Without Docker
Run the backend directly on your machine for faster iteration.
If you prefer running without Docker (faster restarts, easier debugging), you can run Django directly.
Prerequisites
- Python 3.12+
- PostgreSQL 15+ with
pgvectorextension installed - Redis running locally
Setup
cd backend
# Create a virtual environment
python -m venv .venv
source .venv/bin/activate
# Install dependencies
pip install -r requirements/local.txt
# Set environment variables (or create a .env file)
export DATABASE_URL="postgres://user:pass@localhost:5432/hypersaas"
export REDIS_URL="redis://localhost:6379/0"
export DJANGO_SETTINGS_MODULE="config.settings.local"Database Setup
# Ensure pgvector extension exists
psql -d hypersaas -c "CREATE EXTENSION IF NOT EXISTS vector;"
# Run migrations
python manage.py migrate
# Create superuser
python manage.py createsuperuserRun the Server
# Django development server
python manage.py runserver
# In a separate terminal — Celery worker (for async tasks)
celery -A config.celery_app worker -l info
# In another terminal — Celery beat (for scheduled tasks)
celery -A config.celery_app beat -l info --scheduler django_celery_beat.schedulers:DatabaseSchedulerAPI Access
- API root: http://localhost:8000/api/
- Admin panel: http://localhost:8000/admin/
- Swagger docs: http://localhost:8000/api/docs/
- OpenAPI schema: http://localhost:8000/api/schema/