fix: resolve internal docker hostnames to client window location hostname in browser context
All checks were successful
Staging Build / build (push) Successful in 1m49s

This commit is contained in:
DanielS
2026-06-23 02:42:50 +02:00
parent ca69db2395
commit c0c5240f8d
4 changed files with 24 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
import { createServerClient } from "@supabase/ssr";
import { NextResponse, type NextRequest } from "next/server";
import { hasEnvVars } from "../utils";
import { hasEnvVars, resolveSupabaseUrl } from "../utils";
export async function updateSession(request: NextRequest) {
let supabaseResponse = NextResponse.next({
@@ -17,7 +17,7 @@ export async function updateSession(request: NextRequest) {
const supabaseAnonKey = process.env.SUPABASE_ANON_KEY || process.env.NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY || process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY;
const supabase = createServerClient(
supabaseUrl!,
resolveSupabaseUrl(supabaseUrl)!,
supabaseAnonKey!,
{
cookies: {