fix(gateway): copy allowed routes for the edge listener

The edge listener retained the renderer's local allowed-routes value,
while the apex and child listeners already owned independent copies.
Give edge the same ownership so later changes to the local value cannot
reach a rendered listener. The rendered Gateway remains unchanged.

Fixes #4118

Assisted-by: LLM
Signed-off-by: 7487 <1042653432@qq.com>
This commit is contained in:
7487 authored and Aleksei Sviridkin committed 2026-10-08 20:22:39 +08:00
1 parent 382169be52
commit 79e1fb444c
1 file changed
+1 -1
@@ -1432,7 +1432,7 @@ func (r *Reconciler) renderGateway(tgw *gatewayv1alpha1.TenantGateway, dynHostna
Port: 80,
Protocol: gatewayv1.HTTPProtocolType,
Hostname: &wildcardHost,
AllowedRoutes: edgeAllowedRoutes,
AllowedRoutes: edgeAllowedRoutes.DeepCopy(),
},
gatewayv1.Listener{
Name: "edge-apex",