From 0f3459c2e54ca166c9538886bfb22a574be0c830 Mon Sep 17 00:00:00 2001 From: HardAndHeavy Date: Tue, 7 Jul 2026 14:05:51 +0300 Subject: [PATCH] feat: add NEXT_PUBLIC_LOCALE_PREFIX build argument to Dockerfile --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index 2b7c21ae..cd12db32 100644 --- a/Dockerfile +++ b/Dockerfile @@ -8,6 +8,10 @@ ENV NEXT_TELEMETRY_DISABLED=1 # at build time, so it cannot be changed without rebuilding. ARG NEXT_PUBLIC_BASE_PATH= ENV NEXT_PUBLIC_BASE_PATH=$NEXT_PUBLIC_BASE_PATH +# Optional: avoid next-intl rewrite loops when served under a subpath. +# Baked in at build time. +ARG NEXT_PUBLIC_LOCALE_PREFIX= +ENV NEXT_PUBLIC_LOCALE_PREFIX=$NEXT_PUBLIC_LOCALE_PREFIX # Optional: fallback UI locale (e.g. tr, de, fr) used when the visitor's # Accept-Language header does not match any supported locale. Baked in at # build time because next-intl wires it into client-side routing too.