POST Change Kubernetes Cluster Service Account and Service Account Token REST API Operation

This operation updates the service account and service account token for a Kubernetes cluster. The Kubernetes community recommends rotating your infrastructure credentials frequently, and you can use this operation to do that.

Request

Syntax

POST <webservice>/Application  HTTP/1.1
Host: <hostname>
Accept: application/json or application/xml
Content-Type: application/json

where <webservice> is the root path used to route the API requests to the Web Server.

For more information, see Available Web Services for REST API.

Request Headers

Header

Description

Host

The host name of the Web Server or Web Console used in the API request.

Accept

The format of the response.

Valid value is application/json.

Authtoken

The authentication token received after successfully logging on.

For information about receiving an authentication token, see Authentication.

Request Body

To updates the service account token for your Kubernetes service account, download the JSON file required for this request: post_kubernetes_change_ cluster_service_account.json.

Parameter

Description

Element

Parent element

instanceId

The instance ID of the Kubernetes cluster.

To get the instance ID, use GET Kubernetes Instance ID from the Client Name.

appId

prop

clientId

The name of the Kubernetes client.

client

memberServers

endpointurl

The API endpoint URL for the Kubernetes client.

k8s

virtualServerInfo

secretName

The name of the new service account.

k8s

virtualServerInfo

secretKey

The new service account token value.

k8s

virtualServerInfo

secretType

Authentication type for client.

Valid value is: ServiceAccount

k8s

virtualServerInfo

hostName

The API endpoint URL for the Kubernetes client.

virtualServerInfo

prop

vendor

The vendor type of the hypervisor.

Valid value is: KUBERNETES.

virtualServerInfo

prop

Loading...