diff --git a/spectrocloud/resource_cluster_edge_native.go b/spectrocloud/resource_cluster_edge_native.go index 9679d518..4216e573 100644 --- a/spectrocloud/resource_cluster_edge_native.go +++ b/spectrocloud/resource_cluster_edge_native.go @@ -681,7 +681,7 @@ func toOverlayNetworkConfigAndVip(cloudConfig map[string]interface{}) (*models.V controlPlaneEndpoint = &models.V1EdgeNativeControlPlaneEndPoint{ Host: vip, - Type: "IP", + Type: "VIP", } } else { if overlayConfig.Enable { @@ -692,7 +692,7 @@ func toOverlayNetworkConfigAndVip(cloudConfig map[string]interface{}) (*models.V controlPlaneEndpoint = &models.V1EdgeNativeControlPlaneEndPoint{ Host: autoGenVip, - Type: "IP", + Type: "VIP", } } } diff --git a/spectrocloud/resource_cluster_edge_native_test.go b/spectrocloud/resource_cluster_edge_native_test.go index ba5d2989..f470887e 100644 --- a/spectrocloud/resource_cluster_edge_native_test.go +++ b/spectrocloud/resource_cluster_edge_native_test.go @@ -529,7 +529,7 @@ func TestToOverlayNetworkConfigAndVip(t *testing.T) { assert.NoError(t, errValid) assert.Equal(t, &models.V1EdgeNativeControlPlaneEndPoint{ Host: "192.168.1.1", - Type: "IP", + Type: "VIP", }, controlPlaneEndpointValid) assert.Equal(t, &models.V1EdgeNativeOverlayNetworkConfiguration{ Cidr: "10.0.0.0/16", @@ -547,7 +547,7 @@ func TestToOverlayNetworkConfigAndVip(t *testing.T) { assert.NoError(t, errOverlayOnly) assert.Equal(t, &models.V1EdgeNativeControlPlaneEndPoint{ Host: "10.0.0.1", // Automatically generated VIP - Type: "IP", + Type: "VIP", }, controlPlaneEndpointOverlayOnly) assert.Equal(t, &models.V1EdgeNativeOverlayNetworkConfiguration{ Cidr: "10.0.0.0/16", @@ -565,7 +565,7 @@ func TestToOverlayNetworkConfigAndVip(t *testing.T) { assert.NoError(t, errVipOnly) assert.Equal(t, &models.V1EdgeNativeControlPlaneEndPoint{ Host: "192.168.1.1", - Type: "IP", + Type: "VIP", }, controlPlaneEndpointVipOnly) assert.Equal(t, &models.V1EdgeNativeOverlayNetworkConfiguration{ Cidr: "", // Empty CIDR since overlay_cidr_range is missing