From 92006a6957a576c75203738ef178f7bb2f09e688 Mon Sep 17 00:00:00 2001 From: Wesley Su Date: Mon, 27 Nov 2023 20:22:08 +0800 Subject: [PATCH] fix config public ip for tunnel --- pkg/tunnelengine/tunnelagent.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/tunnelengine/tunnelagent.go b/pkg/tunnelengine/tunnelagent.go index aa5559a..4c84c5d 100644 --- a/pkg/tunnelengine/tunnelagent.go +++ b/pkg/tunnelengine/tunnelagent.go @@ -239,7 +239,7 @@ func (c *TunnelHandler) configGatewayPublicIP(gateway *v1beta1.Gateway) error { return err } for k, v := range apiGw.Spec.Endpoints { - if v.NodeName == c.nodeName { + if v.NodeName == c.nodeName && v.Type == v1beta1.Tunnel { apiGw.Spec.Endpoints[k].PublicIP = publicIP err = c.ravenClient.Update(context.Background(), &apiGw) return err