mirror of
https://github.com/supabase/supabase.git
synced 2026-06-23 19:48:02 +08:00
I spent a few hours today trying to work out why I couldn't connect to my local Supabase DB from a local Supabase function. It dawned on me that the `SUPABASE_DB_URL` included the `localhost` string, which would attempt to connect to the DB on the same container as the functions are hosted. Swapping out `localhost` for `host.docker.internal` fixed the issue. Thought it would be worth documenting. Happy to amend or move to a more appropriate place if needs be.