All Products
Search
Document Center

:DescribeKubernetesVersionMetadata

更新时间:Aug 07, 2023

Queries information about the Kubernetes versions that are supported by Container Service for Kubernetes (ACK).

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

This operation uses only common request headers. For more information, refer to the documentation of common request parameters.

Request syntax

GET /api/v1/metadata/versions HTTP/1.1

Request parameters

Parameter Type Position Required Example Description
Region String Query Yes cn-beijing

The region ID of the cluster.

ClusterType String Query Yes Kubernetes

The type of cluster. Valid values:

  • Kubernetes: ACK dedicated cluster
  • ManagedKubernetes: ACK managed cluster
  • ExternalKubernetes: registered cluster
KubernetesVersion String Query No 1.26.3-aliyun.1

The Kubernetes version of the cluster. The Kubernetes versions supported by ACK are the same as the Kubernetes versions supported by open source Kubernetes. We recommend that you specify the latest Kubernetes version. If you do not specify this parameter, the latest Kubernetes version is used.

You can create ACK clusters of the latest two Kubernetes versions in the ACK console. You can call the specific ACK API operation to create clusters of other Kubernetes versions. For more information about the Kubernetes versions supported by ACK, see Release notes for Kubernetes versions.

Profile String Query No Default

The scenario where clusters are used. Valid values:

  • Default: non-edge computing scenarios
  • Edge: edge computing scenarios
  • Serverless: scenarios that require serverless Kubernetes (ASK) clusters

Default value: Default

runtime String Query No containerd

The container runtime type that you want to use. You can specify a runtime type to query only OS images that support the runtime type. Valid values:

  • docker: Docker
  • containerd: containerd
  • Sandboxed-Container.runv: Sandboxed-Container

If you specify a runtime type, only the OS images that support the specified runtime type are returned.

Otherwise, all OS images are returned.

Mode String Query No supported

The query mode. Valid values:

  • supported: queries the Kubernetes versions that are supported.
  • creatable: queries the Kubernetes versions that can be used to create clusters.

If you specify KubernetesVersion, this parameter is ignored.

If you do not specify a query mode, Kubernetes versions that can be used to create clusters are returned.

Response parameters

Parameter Type Example Description
Array of Kubernetes versions

The Kubernetes versions.

capabilities Map

The features of the Kubernetes version.

images Array of Kubernetes images

The OS images.

image_id String centos_7_9_x64_20G_alibase_20221129.vhd

The image ID.

image_name String CentOS 7.9

The image name.

platform String CentOS

The OS platform. Valid values:

  • AliyunLinux
  • CentOS
  • Windows
  • WindowsCore
os_version String 7.9

The image version.

image_type String CentOS

The type of OS distribution that you want to use. To specify the node OS, we recommend that you use this parameter. Valid values:

  • CentOS
  • AliyunLinux
  • AliyunLinux Qboot
  • AliyunLinuxUEFI
  • AliyunLinux3
  • Windows
  • WindowsCore
  • AliyunLinux3Arm64
  • ContainerOS
os_type String Linux

The type of the operating system. Examples:

  • Windows
  • Linux
image_category String system

The type of the image. Examples:

  • system: public image
  • self: custom image
  • others: shared image from another Alibaba Cloud account
  • marketplace: image from the image market
architecture String x86_64

The architecture of the image.

meta_data Map

The metadata of the Kubernetes version.

runtimes Array of runtime

The supported container runtimes.

version String 1.26.3-aliyun.1

The Kubernetes version that is supported by ACK. For more information, see Release notes for Kubernetes versions.

release_date String 2023-04-30T00:00:00Z

The release date of the Kubernetes version.

expiration_date String 2025-04-30T00:00:00Z

The expiration date of the Kubernetes version.

creatable Boolean true

Indicates whether the Kubernetes version can be used to create clusters.

Examples

Sample requests

GET /api/v1/metadata/versions?Region=cn-beijing&ClusterType=Kubernetes&KubernetesVersion=1.26.3-aliyun.1&Profile=Default&runtime=containerd&Mode=supported HTTP/1.1
Host:cs.aliyuncs.com
Content-Type:application/json

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeKubernetesVersionMetadataResponse>
    <images>
        <image_id>centos_7_9_x64_20G_alibase_20221129.vhd</image_id>
        <image_name>CentOS 7.9</image_name>
        <platform>CentOS</platform>
        <os_version>7.9</os_version>
        <image_type>CentOS</image_type>
        <os_type>Linux</os_type>
        <image_category/>
        <architecture>x86_64</architecture>
    </images>
    <runtimes>
        <name>containerd</name>
        <version>1.6.20</version>
    </runtimes>
    <version>1.26.3-aliyun.1</version>
    <release_date>2023-04-30T00:00:00Z</release_date>
    <expiration_date>2025-04-30T00:00:00Z</expiration_date>
    <creatable>true</creatable>
</DescribeKubernetesVersionMetadataResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

[ {
  "images" : [ {
    "image_id" : "centos_7_9_x64_20G_alibase_20221129.vhd",
    "image_name" : "CentOS 7.9",
    "platform" : "CentOS",
    "os_version" : "7.9",
    "image_type" : "CentOS",
    "os_type" : "Linux",
    "image_category" : "",
    "architecture" : "x86_64"
  } ],
  "runtimes" : [ {
    "name" : "containerd",
    "version" : "1.6.20"
  } ],
  "version" : "1.26.3-aliyun.1",
  "release_date" : "2023-04-30T00:00:00Z",
  "expiration_date" : "2025-04-30T00:00:00Z",
  "creatable" : true
} ]

Error codes

For a list of error codes, see Service error codes.