vcenter namespace management clusters: update
Update configuration on the cluster object. The specified configuration is applied partially and unset fields in
spec
will leave those parts of configuration as-is.
Request:
HTTP request
PATCH https://{server}/api/vcenter/namespace-management/clusters/{cluster}
{
"master_DNS_search_domains" : [
"string",
"string"
],
"workload_ntp_servers" : [
"string",
"string"
],
"image_storage" : {
"storage_policy" : "obj-103"
},
"ncp_cluster_network_spec" : {
"default_ingress_tls_certificate" : "string",
"pod_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
],
"egress_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
],
"ingress_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
]
},
"master_NTP_servers" : [
"string",
"string"
],
"ephemeral_storage_policy" : "obj-103",
"default_image_repository" : "string",
"login_banner" : "string",
"size_hint" : "TINY",
"worker_DNS" : [
"string",
"string"
],
"default_image_registry" : {
"hostname" : "string",
"port" : 1
},
"master_DNS" : [
"string",
"string"
],
"tls_endpoint_certificate" : "string",
"network_provider" : "NSXT_CONTAINER_PLUGIN",
"master_storage_policy" : "obj-103",
"default_kubernetes_service_content_library" : "obj-103"
}
"master_DNS_search_domains" : [
"string",
"string"
],
"workload_ntp_servers" : [
"string",
"string"
],
"image_storage" : {
"storage_policy" : "obj-103"
},
"ncp_cluster_network_spec" : {
"default_ingress_tls_certificate" : "string",
"pod_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
],
"egress_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
],
"ingress_cidrs" : [
{
"address" : "string",
"prefix" : 1
},
{
"address" : "string",
"prefix" : 1
}
]
},
"master_NTP_servers" : [
"string",
"string"
],
"ephemeral_storage_policy" : "obj-103",
"default_image_repository" : "string",
"login_banner" : "string",
"size_hint" : "TINY",
"worker_DNS" : [
"string",
"string"
],
"default_image_registry" : {
"hostname" : "string",
"port" : 1
},
"master_DNS" : [
"string",
"string"
],
"tls_endpoint_certificate" : "string",
"network_provider" : "NSXT_CONTAINER_PLUGIN",
"master_storage_policy" : "obj-103",
"default_kubernetes_service_content_library" : "obj-103"
}
Path Parameters
Name | Type | Description |
---|---|---|
Required | ||
cluster | string | Identifier for the cluster on which vSphere Namespaces is enabled. |
Body Parameters:
Name | Type | Description |
---|---|---|
bold = required | ||
- | update_spec | New specification for the cluster. |
-.size_hint | string | This affects the size and resources allocated to the Kubernetes API server. Optional. If unset, size and resources allocated to Kubernetes API server will not be modified. |
-.network_provider | string | The provider of cluster networking for this vSphere Namespaces cluster. Optional. If unset, the existing effective cluster network specification will not be modified. |
-.ncp_cluster_network_spec | NCP_cluster_network_update_spec | Updated specification for the cluster network configuration. Optional. It is only relevant when network_provider has value NSXT_CONTAINER_PLUGIN. If unset, existing effective value will not be modified If unset, the existing effective cluster network specification will not be modified. |
-.ncp_cluster_network_spec.pod_cidrs | ipv4_cidr[] | CIDR blocks from which Kubernetes allocates pod IP addresses. This range should not overlap with those in com.vmware.vcenter.namespace_management.EnableSpec#serviceCidr, vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.ingress_cidrs, vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.egress_cidrs, or other services running in the datacenter. An update operation only allows for addition of new CIDR blocks to the existing list. All Pod CIDR blocks must be of at least subnet size /23. Optional. If unset, CIDRs from which Kubernetes allocates pod IP addresses will not be modified. |
-.ncp_cluster_network_spec.pod_cidrs[].address | string | The IPv4 address. |
-.ncp_cluster_network_spec.pod_cidrs[].prefix | long | The CIDR prefix. |
-.ncp_cluster_network_spec.ingress_cidrs | ipv4_cidr[] | CIDR blocks from which NSX assigns IP addresses for Kubernetes Ingresses and Kubernetes Services of type LoadBalancer. These ranges should not overlap with those in vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.pod_cidrs, com.vmware.vcenter.namespace_management.EnableSpec#serviceCidr, vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.egress_cidrs, or other services running in the datacenter. An update operation only allows for addition of new CIDR blocks to the existing list. Optional. If unset, CIDRs from which Kubernetes allocates ingress IP addresses will not be modified. |
-.ncp_cluster_network_spec.ingress_cidrs[].address | string | The IPv4 address. |
-.ncp_cluster_network_spec.ingress_cidrs[].prefix | long | The CIDR prefix. |
-.ncp_cluster_network_spec.egress_cidrs | ipv4_cidr[] | CIDR blocks from which NSX assigns IP addresses used for performing SNAT from container IPs to external IPs. These ranges should not overlap with those in vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.pod_cidrs, com.vmware.vcenter.namespace_management.EnableSpec#serviceCidr, vcenter.namespace_management.clusters.NCP_cluster_network_update_spec.ingress_cidrs, or other services running in the datacenter. An update operation only allows for addition of new CIDR blocks to the existing list. Optional. If unset, CIDR from which Kubernetes allocates egress IP addresses will not be modified. |
-.ncp_cluster_network_spec.egress_cidrs[].address | string | The IPv4 address. |
-.ncp_cluster_network_spec.egress_cidrs[].prefix | long | The CIDR prefix. |
-.ncp_cluster_network_spec.default_ingress_tls_certificate | string | PEM-encoded x509 certificate used by NSX as a default fallback certificate for Kubernetes Ingress services. Optional. |
-.master_DNS | string[] | List of DNS server IP addresses to use on Kubernetes API server, specified in order of preference. Optional. If set, DNS servers set on Kubernetes API server will be replaced. Otherwise, they will not be modified. |
-.worker_DNS | string[] | List of DNS server IP addresses to use on the worker nodes, specified in order of preference. Optional. If set, DNS servers set on worker nodes will be replaced. Otherwise, they will not be modified. |
-.master_DNS_search_domains | string[] | List of domains (for example "vmware.com") to be searched when trying to lookup a host name on Kubernetes API server, specified in order of preference. Optional. If set, DNS search domains on Kubernetes API server will be replaced. Otherwise, they will not be modified. |
-.master_NTP_servers | string[] | List of NTP server DNS names or IP addresses to use on Kubernetes API server, specified in order of preference. Optional. If set, NTP servers on Kubernetes API server will be replaced. Otherwise, they will not be modified. |
-.master_storage_policy | string | Identifier of storage policy associated with Kubernetes API server. Optional. If unset, storage policy associated with Kubernetes API server will not be modified.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: SpsStorageProfile . When operations return a value of this structure as a result, the field will be an identifier for the resource type: SpsStorageProfile . |
-.ephemeral_storage_policy | string | Identifier of storage policy associated with ephemeral disks of all the Kubernetes Pods in the cluster. Optional. If unset, storage policy associated with ephemeral disks of all the Kubernetes Pods will not be modified.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: SpsStorageProfile . When operations return a value of this structure as a result, the field will be an identifier for the resource type: SpsStorageProfile . |
-.login_banner | string | Disclaimer to be displayed prior to login via the Kubectl plugin. Optional. If unset, disclaimer to be displayed prior to login via the Kubectl plugin will not be modified. |
-.image_storage | image_storage_spec | Specification for storage to be used for container images. Optional. If unset, configuration of storage used for container images is not modified. |
-.image_storage.storage_policy | string | Identifier of the storage policy. When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: SpsStorageProfile . When operations return a value of this structure as a result, the field will be an identifier for the resource type: SpsStorageProfile . |
-.default_image_registry | image_registry | Default image registry to use when Kubernetes Pod container specification does not specify it as part of the container image name. Optional. If unset, default image registry will not be modified. |
-.default_image_registry.hostname | string | IP address or the hostname of container image registry. |
-.default_image_registry.port | long | Port number of the container image registry. Optional. If unset, defaults to 443. |
-.default_image_repository | string | Default image repository to use when Kubernetes Pod container specification does not specify it as part of the container image name. Optional. If unset, default image repository will not be modified. |
-.tls_endpoint_certificate | string | Certificate issued for Kubernetes API Server. Certificate used must be created by signing the Certificate Signing Request obtained from com.vmware.vcenter.namespace_management.certificates.Request.create Because a CertificateSigningRequest is created on an existing Namespaces-enabled Cluster , you must use the update_spec to specify this tlsEndpointCertificate on an existing Cluster rather than during initially enabling Namespaces on a Cluster . Optional. If unset, Kubernetes API Server certificate will not be modified. |
-.default_kubernetes_service_content_library | string | Identifier of the Content Library which holds the VM Images for vSphere Kubernetes Service. This Content Library should be subscribed to VMware's hosted vSphere Kubernetes Service Repository. Modifying or clearing the Content Library identifier will not affect existing vSphere Kubernetes Service clusters. However, upgrades or scale-out of existing clusters may be affected if the new Content Library doesn't have the necessary VM Images. Optional. If unset, the Content Library identifier will not be modified.When clients pass a value of this structure as a parameter, the field must be an identifier for the resource type: com.vmware.content.Library . When operations return a value of this structure as a result, the field will be an identifier for the resource type: com.vmware.content.Library . |
-.workload_ntp_servers | string[] | List of NTP server DNS names or IP addresses to use for workloads such as Tanzu Kubernetes Grid VMs, specified in order of preference. This attribute was added in vSphere API 7.0.1.0. Optional. If unset, NTP servers for workloads will be unmodified. |
Response:
HTTP Status Code: 204
Headers:
NoneType:
NoneErrors:
HTTP Status Code | Type | Description |
---|---|---|
500 | error | if the system reports an error while responding to the request. |
400 | invalid_argument | if spec contain any errors. |
400 | not_allowed_in_current_state | if vSphere Namespaces is being disabled on this cluster. |
404 | not_found | if cluster could not be located. |
401 | unauthenticated | if the user can not be authenticated. |
403 | unauthorized | if the user does not have Namespaces.Manage privilege. |