All Products
Search
Document Center

Container Service for Kubernetes:FixNodePoolVuls

Last Updated:Nov 07, 2024

Patches node vulnerabilities in a node pool to enhance node security. Cloud Security provided by Alibaba Cloud periodically scans Elastic Compute Service (ECS) instances for vulnerabilities and provides suggestions on how to patch the detected vulnerabilities. Vulnerability patching may require node restarts. Make sure that your cluster has sufficient idle nodes for node draining.

Operation description

  1. The Common Vulnerabilities and Exposures (CVE) patching feature is developed based on Security Center. To use this feature, you must purchase the Security Center Ultimate Edition that supports Container Service for Kubernetes (ACK).
  2. ACK may need to restart nodes to patch certain vulnerabilities. ACK drains a node before the node restarts. Make sure that the ACK cluster has sufficient idle nodes to host the pods evicted from the trained nodes. For example, you can scale out a node pool before you patch vulnerabilities for the nodes in the node pool.
  3. Security Center ensures the compatibility of CVE patches. We recommend that you check the compatibility of a CVE patch with your application before you install the patch. You can pause or cancel a CVE patching task anytime.
  4. CVE patching is a progressive task that consists of multiple batches. After you pause or cancel a CVE patching task, ACK continues to process the dispatched batches. Only the batches that have not been dispatched are paused or canceled.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
cs:FixNodePoolVulsupdate
  • Cluster
    acs:cs:{#regionId}:{#accountId}:cluster/{#cluster_id}
    none
none

Request syntax

POST /clusters/{cluster_id}/nodepools/{nodepool_id}/vuls/fix HTTP/1.1

Request parameters

ParameterTypeRequiredDescriptionExample
cluster_idstringYes

The cluster ID.

cf62854ac2130470897be7a27ed1f****
nodepool_idstringYes

The node pool ID.

np31da1b38983f4511b490fc62108a****
bodyobjectNo

The request body.

vulsarrayNo

The list of vulnerabilities.

stringNo

The name of the vulnerability.

oval:com.redhat.rhsa:def:20170574
nodesarrayNo

The names of the nodes to be patched.

stringNo

The node name.

cn-beijing.10.0.1.26
rollout_policyobjectNo

The batch patching policy.

max_parallelismlongNo

The maximum concurrency for batch patching. Minimum value: 1. The maximum value equals the number of nodes in the node pool.

1
auto_restartbooleanNo

Specifies whether to allow the nodes to restart.

true

Response parameters

ParameterTypeDescriptionExample
object
task_idstring

The ID of the CVE patching task.

T-60fea8ad2e277f087900****

Examples

Sample success responses

JSONformat

{
  "task_id": "T-60fea8ad2e277f087900****"
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-11-20The internal configuration of the API is changed, but the call is not affectedView Change Details
2023-07-21The internal configuration of the API is changed, but the call is not affectedView Change Details