Create K 8s Cluster
Creates a new Kubernetes cluster. This operation is asynchronous and returns a task that you can monitor to track the progress of the request.
Request
URI
POST
https://{api_host}/cloudapi/1.0.0/tkgClusters
COPY
Request Body
Example Value for CSE Native cluster
{ "metadata": { "name": "my-CSE-Native-cluster", "site": "", "orgName": "my-organization", "virtualDataCenterName": "my-org-vdc" }, "apiVersion": "cse.vmware.com/v2.0", "kind": "native", "spec": { "expose": false, "settings": { "sshKey": null, "network": null, "ovdcNetwork": "network-in-my-org-vdc", "rollbackOnFailure": true }, "topology": { "workers": { "count": 1 }, "controlPlane": { "count": 1 } }, "distribution": { "templateName": "ubuntu-16.04_k8-1.18_weave-2.6.5", "templateRevision": 2 } } }
Example Value for TKGS cluster
{ "kind": "TanzuKubernetesCluster", "metadata": { "name": "my-TKGS-cluster", "placementPolicy": "my-placement-policy", "virtualDataCenterName": "my-org-vdc" }, "spec": { "distribution": { "version": "v1.20.2" }, "topology": { "controlPlane": { "class": "best-effort-xsmall", "count": 1, "storageClass": "my-storage-class" }, "workers": { "class": "best-effort-xsmall", "count": 1, "storageClass": "my-storage-class" } } } }
Cluster of type(s) application/json
Required
{
"kind": "string",
"apiVersion": "string"
}
string
kind
Optional
kind
string
apiVersion
Optional
apiVersion
object
metadata
Optional
metadata
object
spec
Optional
spec
object
status
Optional
status
Responses
202
The request have been accepted and the task to monitor the request is in the Location header.
Operation doesn't return any data structure
400
Invalid configuration.
Returns Error of type(s) */*;version=38.1
{
"minorErrorCode": "string",
"message": "string",
"stackTrace": "string"
}
string
minorErrorCode
Required
minorErrorCode
string
message
Required
message
string
stackTrace
Optional
stackTrace
Availability
Added in 39.0.0-alpha
K8s Cluster Operations
POST
Create K 8s Cluster
DELETE
Delete K 8s Cluster
POST
Generate Kubeconfig
GET
Get K 8s Cluster
GET
Query K 8s Clusters
PUT
Update K 8s Cluster