Ga naar inhoud

Supabase CLI

HostStuff ondersteunt het deel van de Supabase Management API dat de Supabase CLI nodig heeft voor koppelen, Edge Functions en secrets. Getest met CLI-versie 3.1.

Maak onder Account in het dashboard een persoonlijk toegangstoken (sbp_…). Je kunt er maximaal 20 hebben. HostStuff bewaart alleen een hash: kopieer het token meteen.

Terminal window
export SUPABASE_ACCESS_TOKEN=sbp_...

Maak een bestand hoststuff.yaml:

name: hoststuff
api_url: https://app.hoststuff.nl
project_host: api.hoststuff.nl
dashboard_url: https://app.hoststuff.nl

Gebruik de CLI-ref van je project: 20 kleine letters, te vinden onder Supabase → Overzicht → Verbinden.

Terminal window
supabase --profile hoststuff.yaml link --project-ref <cli-ref>
Terminal window
# Edge Functions: HostStuff bouwt niets, de CLI levert de bundel aan
supabase --profile hoststuff.yaml functions deploy <naam> --use-api
supabase --profile hoststuff.yaml functions list
supabase --profile hoststuff.yaml functions delete <naam>
# Secrets voor Edge Functions
supabase --profile hoststuff.yaml secrets set NAAM=waarde
supabase --profile hoststuff.yaml secrets list
supabase --profile hoststuff.yaml secrets unset NAAM
  • Een functie is maximaal 900 KiB (gecomprimeerd).
  • verify_jwt geldt voor het hele project, niet per functie.

Andere Management API-endpoints geven 404 Not implemented on HostStuff.

Migraties zet je via de pooler (sessiemodus) door:

Terminal window
supabase db push --db-url "postgresql://postgres.<ref>:<wachtwoord>@pooler.hoststuff.nl:5432/postgres?sslmode=require"