From a43e3b56e196601a223c50a12598ceae9ab8d53e Mon Sep 17 00:00:00 2001 From: Vadko Date: Mon, 9 Mar 2026 02:32:28 +0200 Subject: [PATCH] fix: use separate secret for Logflare private access token Using the same secret for both LOGFLARE_PUBLIC_ACCESS_TOKEN and LOGFLARE_PRIVATE_ACCESS_TOKEN causes Supabase Studio logs to return 401 Unauthorized. Logflare requires the private token to have 'private' scope in the oauth_access_tokens table, but when both tokens share the same value, only the public scope is registered. Separate SERVICE_PASSWORD_LOGFLARE_PRIVATE secret ensures Logflare generates distinct tokens with correct scopes on startup. --- templates/compose/supabase.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/compose/supabase.yaml b/templates/compose/supabase.yaml index f0f2cdd31..75d5a1e25 100644 --- a/templates/compose/supabase.yaml +++ b/templates/compose/supabase.yaml @@ -355,7 +355,7 @@ services: - LOGFLARE_API_KEY=${SERVICE_PASSWORD_LOGFLARE} - LOGFLARE_PUBLIC_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE} - - LOGFLARE_PRIVATE_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE} + - LOGFLARE_PRIVATE_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE_PRIVATE} - LOGFLARE_URL=http://supabase-analytics:4000 # Next.js client-side environment variables (required for browser access) - 'NEXT_PUBLIC_SUPABASE_URL=${SERVICE_URL_SUPABASEKONG}' @@ -694,7 +694,7 @@ services: - DB_PASSWORD=${SERVICE_PASSWORD_POSTGRES} - DB_SCHEMA=_analytics - LOGFLARE_PUBLIC_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE} - - LOGFLARE_PRIVATE_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE} + - LOGFLARE_PRIVATE_ACCESS_TOKEN=${SERVICE_PASSWORD_LOGFLARE_PRIVATE} - LOGFLARE_SINGLE_TENANT=true - LOGFLARE_SUPABASE_MODE=true