nav-img
Advanced

Updating a Cluster Daemonset

Function

This API is used to update a cluster daemonset.

URI

PUT /v5/{project_id}/container/kubernetes/clusters/{cluster_id}/daemonsets

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Project ID

cluster_id

Yes

String

Cluster ID

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

enterprise_project_id

No

String

Enterprise project ID. To query all enterprise projects, set this parameter to all_granted_eps.

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

User token.

It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is a token.

region

Yes

String

Region ID

Table 4 Request body parameters

Parameter

Mandatory

Type

Description

agent_version

No

String

Agent version

cluster_name

No

String

Cluster name

auto_upgrade

No

Boolean

Enable automatic agent upgrade.

runtime_info

No

Array of RuntimeRequestBody objects

Container runtime configuration

schedule_info

No

Node scheduling information

invoked_service

No

String

Calling service. The default value is hss, which is used in the CCE integration protection calling scenario. The options are as follows:

  • hss

  • cce

charging_mode

No

String

Billing mode, which is used in the scenario where CCE integrated protection is called. The value can be:

  • on_demand: pay-per-use

  • free_security_check: free of charge

cce_protection_type

No

String

CCE protection type, which is used in the CCE integration protection scenario. The value can be:

  • cluster_level: cluster-level protection

  • node_level: node-level protection

prefer_packet_cycle

No

Boolean

Only purchase quota in pay-per-use mode is supported. This parameter is used in the CCE integration protection calling scenario. The value is false.

Table 5 RuntimeRequestBody

Parameter

Mandatory

Type

Description

runtime_name

No

String

Runtime name. Its value can be:

  • crio_endpoint: CRIO

  • containerd_endpoint: Containerd

  • docker_endpoint: Docker

  • isulad_endpoint: Isulad

  • podman_endpoint: Podman

runtime_path

No

String

Runtime path

Table 6 schedule_info

Parameter

Mandatory

Type

Description

node_selector

No

Array of strings

Node selector

pod_tolerances

No

Array of strings

Pod tolerance

Response Parameters

None

Example Requests

Update a cluster daemonset.

PUT https://{endpoint}/v5/{project_id}/container/kubernetes/clusters/{cluster_id}/daemonsets
{
"cluster_id" : "441e4d05-7f90-11ee-b311-0255ac1001b2"
}

Example Responses

None

Status Codes

Status Code

Description

200

Request succeeded.

Error Codes