Skip to content

Commit a1e476c

Browse files
fix: add namespace to vcluster identifier and name to make it unique
1 parent 8c0d1f0 commit a1e476c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmd/ctrlc/root/sync/kubernetes/vcluster.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,8 +192,8 @@ func NewSyncVclusterCmd() *cobra.Command {
192192
}
193193

194194
resource := api.CreateResource{
195-
Name: fmt.Sprintf("%s/%s", clusterResource.Name, vcluster.Name),
196-
Identifier: fmt.Sprintf("%s/vcluster/%s", clusterResource.Identifier, vcluster.Name),
195+
Name: fmt.Sprintf("%s/%s/%s", clusterResource.Name, vcluster.Namespace, vcluster.Name),
196+
Identifier: fmt.Sprintf("%s/%s/vcluster/%s", clusterResource.Identifier, vcluster.Namespace, vcluster.Name),
197197
Kind: fmt.Sprintf("%s/%s", clusterResource.Kind, vclusterKind),
198198
Version: "ctrlplane.dev/kubernetes/cluster/v1",
199199
Metadata: metadata,

0 commit comments

Comments
 (0)