查询集群内所有节点池列表。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
下表是API对应的授权信息,可以在RAM权限策略语句的Action
元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:
- 操作:是指具体的权限点。
- 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
- 资源类型:是指操作中支持授权的资源类型。具体说明如下:
- 对于必选的资源类型,用背景高亮的方式表示。
- 对于不支持资源级授权的操作,用
全部资源
表示。
- 条件关键字:是指云产品自身定义的条件关键字。
- 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
操作 | 访问级别 | 资源类型 | 条件关键字 | 关联操作 |
---|---|---|---|---|
cs:DescribeClusterNodePools | get | *Cluster acs:cs:{#regionId}:{#accountId}:cluster/{#ClusterId} |
| 无 |
请求语法
GET /clusters/{ClusterId}/nodepools HTTP/1.1
请求参数
名称 | 类型 | 必填 | 描述 | 示例值 |
---|---|---|---|---|
ClusterId | string | 是 | 集群 ID。 | cc0f87de0b8fb403f86e10e204f83**** |
NodepoolName | string | 否 | 节点池名称。 | nodepool-test |
返回参数
示例
正常返回示例
JSON
格式
{
"nodepools": [
{
"nodepool_info": {
"nodepool_id": "np615c0e0966124216a0412e10afe0****",
"name": "default-nodepool",
"type": "ess",
"is_default": true,
"resource_group_id": "rg-acfmyvw3wjm****",
"region_id": "cn-beijing",
"created": "2020-09-27T19:14:09.156823496+08:00",
"updated": "2020-09-27T20:37:46+08:00"
},
"status": {
"state": "active",
"healthy_nodes": 3,
"initial_nodes": 0,
"failed_nodes": 0,
"offline_nodes": 0,
"removing_nodes": 0,
"serving_nodes": 3,
"total_nodes": 3
},
"auto_scaling": {
"enable": true,
"type": "cpu",
"max_instances": 10,
"min_instances": 2,
"eip_internet_charge_type": "PayByBandwidth",
"is_bond_eip": true,
"eip_bandwidth": 5
},
"management": {
"enable": true,
"auto_repair": true,
"auto_repair_policy": {
"restart_node": true
},
"auto_vul_fix": true,
"auto_vul_fix_policy": {
"restart_node": true,
"vul_level": "asap,nntf"
},
"auto_upgrade": true,
"auto_upgrade_policy": {
"auto_upgrade_kubelet": true
},
"upgrade_config": {
"auto_upgrade": true,
"surge": 5,
"surge_percentage": 50,
"max_unavailable": 1
}
},
"scaling_group": {
"scaling_group_id": "asg-2ze8n5qw4atggut8****",
"vswitch_ids": [
"vsw-2ze3ds0mdip0hdz8i****"
],
"instance_types": [
"ecs.n4.large"
],
"instance_charge_type": "PostPaid",
"period": 1,
"period_unit": "Month",
"auto_renew": false,
"auto_renew_period": 0,
"spot_strategy": "NoSpot",
"spot_price_limit": [
{
"instance_type": "ecs.c6.large",
"price_limit": "0.39"
}
],
"image_type": "AliyunLinux",
"image_id": "aliyun_2_1903_x64_20G_alibase_20200529.vhd",
"system_disk_category": "cloud_efficiency",
"system_disk_categories": [
"EESSD云盘"
],
"system_disk_size": 120,
"system_disk_performance_level": "PL1",
"system_disk_encrypted": false,
"system_disk_kms_key_id": "0e478b7a-4262-4802-b8cb-00d3fb40****",
"system_disk_encrypt_algorithm": "aes-256",
"system_disk_bursting_enabled": true,
"system_disk_provisioned_iops": 1000,
"data_disks": [
{
"category": "cloud_ssd",
"size": 40,
"encrypted": "true",
"kms_key_id": "0e478b7a-4262-4802-b8cb-00d3fb40****",
"auto_snapshot_policy_id": "sp-2zej1nogjvovnz4z****",
"performance_level": "PL1",
"provisioned_iops": 1000,
"bursting_enabled": true,
"auto_format": true,
"file_system": "ext4",
"mount_target": "/mnt/path1",
"disk_name": "DataDiskName",
"device": "/dev/xvdb",
"snapshot_id": "s-280s7****"
}
],
"security_group_ids": [
"sg-2ze1iuk12m2sb4c4****"
],
"key_pair": "pro-nodepool",
"login_password": "******",
"login_as_non_root": true,
"cis_enabled": false,
"soc_enabled": false,
"security_hardening_os": true,
"internet_charge_type": "PayByBandwidth",
"internet_max_bandwidth_out": 10,
"tags": [
{
"key": "env",
"value": "prod"
}
],
"desired_size": 2,
"multi_az_policy": "COST_OPTIMIZED",
"scaling_policy": "release",
"on_demand_base_capacity": 0,
"on_demand_percentage_above_base_capacity": 20,
"spot_instance_pools": 5,
"spot_instance_remedy": false,
"compensate_with_on_demand": true,
"deploymentset_id": "ds-bp1d19mmbsv3jf6xxxxx",
"rds_instances": [
"rm-xxx"
],
"private_pool_options": {
"id": "eap-bp67acfmxazb4****",
"match_criteria": "Open"
},
"security_group_id": "sg-2ze1iuk12m2sb4c4****",
"platform": "AliyunLinux",
"ram_policy": "KubernetesWorkerRole-021dc54f-929b-437a-8ae0-34c24d3e****",
"instance_patterns": [
{
"core": 4,
"memory": 8,
"instance_family_level": "EnterpriseLevel",
"max_price": 2,
"architectures": [
"X86"
],
"burst_performance_option": "Exclude",
"excluded_instance_types": [
"ecs.c6.large"
]
}
],
"ram_role_name": "KubernetesWorkerRole-4a4fa089-80c1-48a5-b3c6-9349311f****"
},
"node_config": {
"kubelet_configuration": {
"registryPullQPS": 5,
"registryBurst": 10,
"eventRecordQPS": 5,
"eventBurst": 10,
"kubeAPIQPS": 5,
"kubeAPIBurst": 10,
"serializeImagePulls": true,
"cpuManagerPolicy": "none",
"evictionHard": {
"test": "test",
"test2": 1
},
"evictionSoft": {
"test": "test",
"test2": 1
},
"evictionSoftGracePeriod": {
"test": "test",
"test2": 1
},
"systemReserved": {
"test": "test",
"test2": 1
},
"kubeReserved": {
"test": "test",
"test2": 1
},
"readOnlyPort": 0,
"maxPods": 110,
"containerLogMaxSize": "10Mi",
"containerLogMaxFiles": 5,
"featureGates": {
"test": "test",
"test2": 1
},
"allowedUnsafeSysctls": [
"net.core.somaxconn"
]
}
},
"kubernetes_config": {
"labels": [
{
"key": "env",
"value": "prod"
}
],
"taints": [
{
"key": "key",
"value": "value",
"effect": "NoSchedule"
}
],
"runtime": "docker",
"runtime_version": "19.03.5",
"cpu_policy": "none",
"user_data": "IyEvYmluL3NoCmVjaG8gIkhlbGxvIEFD****",
"unschedulable": true,
"cms_enabled": true,
"node_name_mode": "customized,test.,5,.com",
"pre_user_data": "IyEvYmluL3NoCmVjaG8gIkhlbGxvIEFD"
},
"tee_config": {
"tee_enable": false
},
"interconnect_config": {
"cen_id": "cen-ey9k9nfhz0f*******",
"ccn_id": "ccn-qm5i0i0q9yi*******",
"ccn_region_id": "cn-shanghai",
"bandwidth": 10,
"improved_period": "1"
},
"max_nodes": 10,
"interconnect_mode": "basic"
}
]
}
错误码
访问错误中心查看更多错误码。
变更历史
变更时间 | 变更内容概要 | 操作 |
---|---|---|
2024-09-27 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2024-07-09 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2024-06-13 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2024-06-13 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2024-05-07 | OpenAPI 入参发生变更 | 查看变更详情 |
2024-04-22 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2024-01-19 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2023-12-13 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2023-10-17 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2023-08-23 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2020-09-24 | OpenAPI 返回结构发生变更 | 查看变更详情 |
2020-09-24 | OpenAPI 返回结构发生变更 | 查看变更详情 |