PreRequisites
- Docker
Also copy and configure default environment variables
cp .env.example .env
Be sure to change sensitive information such as
POSTGRES_PASSWORD
DASHBOARD_USERNAME
DASHBOARD_PASSWORD
You should also create and set keys https://supabase.com/docs/guides/self-hosting/docker#generate-api-keys
JWT_SECRET
ANON_KEY
SERVICE_ROLE_KEY
docker compose up -d
Access through https://localhost:8000
Use the DASHBOARD_USERNAME
and DASHBOARD_USERNAME
variables set in .env
PreRequisites
docker compose -f docker-compose.yml -f ./dev/docker-compose.dev.yml up --renew-anon-volumes
or
deno task start:dev
This is a minimal Docker Compose setup for self-hosting Supabase. Follow the steps here to get started.
analytics requires docker daemon exposed on tcp://localhost:2375
If running docker on windows via docker desktop, need to enable from settings
Expose daemon on tcp://localhost:2375 without TLS
- Why does this not use Supabase CLI, with commands like
supabase start
orsupabase migrate
The supabase CLI is designed to only run development mode containers locally, and communicate with a production instance running on the supabase platform. In order to run a local production instance a custom docker-based approach is requried.
- Why does local development use Deno instead of Node
As Supabase function development is written in Deno it makes sense to require one single runtime throughout instead of multiple