The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
fix(self-hosted): api key translation should depend on the sb_ keys present (#45195)
Luiz Felipe Machado53060160aaa7
diff --git a/docker/volumes/api/envoy/lds.template.yaml b/docker/volumes/api/envoy/lds.template.yamlindex 26038d78060..f9ed9adf0dc 100644--- a/docker/volumes/api/envoy/lds.template.yaml+++ b/docker/volumes/api/envoy/lds.template.yaml@@ -867,8 +867,11 @@ resources:inline_code: |local ANON_KEY = "${ANON_KEY}"local SERVICE_ROLE_KEY = "${SERVICE_ROLE_KEY}"+ local SUPABASE_PUBLISHABLE_KEY = "${SUPABASE_PUBLISHABLE_KEY}"+ local SUPABASE_SECRET_KEY = "${SUPABASE_SECRET_KEY}"local ANON_KEY_ASYMMETRIC = "${ANON_KEY_ASYMMETRIC}"local SERVICE_ROLE_KEY_ASYMMETRIC = "${SERVICE_ROLE_KEY_ASYMMETRIC}"+ local TRANSLATION_ENABLED = SUPABASE_SECRET_KEY ~= "" and SUPABASE_PUBLISHABLE_KEY ~= "" and SERVICE_ROLE_KEY_ASYMMETRIC ~= "" and ANON_KEY_ASYMMETRIC ~= ""local PROTECTED_ROUTES = {["auth-v1-protected"] = true,@@ -900,11 +903,11 @@ resources:return trueend- if SERVICE_ROLE_KEY_ASYMMETRIC ~= "" and apikey == SERVICE_ROLE_KEY_ASYMMETRIC then+ if TRANSLATION_ENABLED and apikey == SERVICE_ROLE_KEY_ASYMMETRIC thenreturn trueend- if ANON_KEY_ASYMMETRIC ~= "" and apikey == ANON_KEY_ASYMMETRIC then+ if TRANSLATION_ENABLED and apikey == ANON_KEY_ASYMMETRIC thenreturn trueend