Cluster has been created using TMC API and there is a need to detach/unmanage it using TMC API. The cluster should only be unmanaged and not deleted.
TMC with clusters managed by TMC
A HTTP PATCH can be invoked on the cluster object with tmcManaged set to false.
{
"fullName": {
"managementClusterName": "string",
"provisionerName": "string",
"name": "string"
},
"patch": [
{
"op": "add",
"path": "spec.tmcManaged",
"value": false
},
{
"op": "add",
"path": "spec.clusterGroupName",
"value": "re-prod"
}
]
}
This will remove TMC namespace and its contents from the cluster. It also removes the cluster from the TMC Cluster group.
If any additional TMC objects need to be removed from the cluster, please refer to the Manage Detached Cluster Resources documentation