docker-compose-local.yml file that starts the Django application together with its own PostgreSQL 16 database and Redis 7 instance. UASAM and Brain use separate databases on different host ports to avoid conflicts, so both stacks can run simultaneously on the same machine.
Starting the services
Start UASAM
UASAM manages users, projects, agents, and all key issuance. Its Compose stack starts Django on port 8000, PostgreSQL 16 on port 5432, and Redis 7 on port 6379.Wait until the log output shows
Starting development server at http://0.0.0.0:8000/ before moving to the next step. The stack runs makemigrations and migrate automatically on first boot.Start Brain
Brain captures events and serves analytics. Its Compose stack starts Django on port 8002, PostgreSQL 16 on port 5433, Redis 7 on port 6378, and two Celery processes (worker and beat) for async event processing.Brain’s Django container maps internal port 8000 to host port 8002 — this is by design so both stacks can share the same internal port convention without conflicting on the host.
Start the frontend
The React dashboard is not included in the backend Compose stacks. Run it with npm for the full hot-reload development experience:Alternatively, use the frontend’s own Compose file, which builds the production image and serves it on port 3000:The Vite dev server is available at http://localhost:5173; the Docker build at http://localhost:3000.
What each Compose stack includes
UASAM stack
uasam-backend— Django 5.0 on port 8000, auto-migrates on startuasam-db— PostgreSQL 16 on host port 5432uasam-redis— Redis 7 on host port 6379
Brain stack
brain-backend— Django 5.0 on port 8002, auto-migrates on startbrain-celery— Celery worker for async event processingbrain-celery-beat— Celery beat schedulerbrain-db— PostgreSQL 16 on host port 5433brain-redis— Redis 7 on host port 6378
UASAM Postgres runs on host port 5432 and Brain Postgres runs on host port 5433. The different host ports prevent conflicts when both stacks run simultaneously on the same machine.
Stopping and cleaning up
PressCtrl+C in the terminal running each stack to stop the containers. To remove containers and their volumes completely:
backend/uasam/docker-compose and backend/brain/docker-compose) separately. The -v flag removes the named volumes, which erases all stored data — omit it if you want to preserve the database across restarts.