Category: baas · database · postgres · self-hosted
OS: Ubuntu 24.04 · Version: 0.7.0
Overview
Supabase is an open-source Firebase alternative used for Postgres with authentication, storage, realtime subscriptions, and auto-generated APIs, all in one stack. This image comes with the whole stack installed but switched off, and the gateway closed, so nobody can reach your database before you do. There is nothing to answer during setup, it runs automatically the first time you log in and takes about five minutes since it’s starting eleven services.What is on this image
Everything below sits on top of a stock Ubuntu 24.04 server.1. Connect
Once your Compute is running, SSH in as root:/opt/sc/supabase/setup.sh there instead.
Setup generates this Compute’s own secrets and API keys, starts the stack, and waits until the database, auth, and Studio are all answering.
2. Open Studio
Setup prints your URL, username, and password when it finishes:3. Get your API keys
Youranon and service_role keys, the database password, and the connection strings all come from one command:
http://YOUR_COMPUTE_IP:8000 using the anon key.
4. Add a domain and HTTPS
Worth doing early, until you do traffic to Studio and to your APIs travels unencrypted. Point an A record at your Compute’s public IP, then run:Managing it
Security
The firewall allows SSH, the Supabase gateway, and the Strettch Cloud agent. Everything else coming in is blocked.fail2ban watches SSH, ten failed logins bans an IP for six hours, with longer bans for repeat offenders, up to a week.
Postgres access depends on how the Supabase stack’s Docker ports are configured.
Verify your own exposure with
nc -zv YOUR_COMPUTE_IP 5432 from an external
machine since Docker’s own port publishing can bypass ufw rules even when
ufw status shows the port as blocked.