GetKubernetesServiceVersions

Use this data source to retrieve the version of Kubernetes supported by Azure Kubernetes Service.

Example Usage

using Pulumi;
using Azure = Pulumi.Azure;

class MyStack : Stack
{
    public MyStack()
    {
        var current = Output.Create(Azure.ContainerService.GetKubernetesServiceVersions.InvokeAsync(new Azure.ContainerService.GetKubernetesServiceVersionsArgs
        {
            Location = "West Europe",
        }));
        this.Versions = current.Apply(current => current.Versions);
        this.LatestVersion = current.Apply(current => current.LatestVersion);
    }

    [Output("versions")]
    public Output<string> Versions { get; set; }
    [Output("latestVersion")]
    public Output<string> LatestVersion { get; set; }
}
package main

import (
    "github.com/pulumi/pulumi-azure/sdk/v3/go/azure/containerservice"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        current, err := containerservice.GetKubernetesServiceVersions(ctx, &containerservice.GetKubernetesServiceVersionsArgs{
            Location: "West Europe",
        }, nil)
        if err != nil {
            return err
        }
        ctx.Export("versions", current.Versions)
        ctx.Export("latestVersion", current.LatestVersion)
        return nil
    })
}
import pulumi
import pulumi_azure as azure

current = azure.containerservice.get_kubernetes_service_versions(location="West Europe")
pulumi.export("versions", current.versions)
pulumi.export("latestVersion", current.latest_version)
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";

const current = azure.containerservice.getKubernetesServiceVersions({
    location: "West Europe",
});
export const versions = current.then(current => current.versions);
export const latestVersion = current.then(current => current.latestVersion);

Using GetKubernetesServiceVersions

function getKubernetesServiceVersions(args: GetKubernetesServiceVersionsArgs, opts?: InvokeOptions): Promise<GetKubernetesServiceVersionsResult>
function  get_kubernetes_service_versions(include_preview=None, location=None, version_prefix=None, opts=None)
func GetKubernetesServiceVersions(ctx *Context, args *GetKubernetesServiceVersionsArgs, opts ...InvokeOption) (*GetKubernetesServiceVersionsResult, error)
public static class GetKubernetesServiceVersions {
    public static Task<GetKubernetesServiceVersionsResult> InvokeAsync(GetKubernetesServiceVersionsArgs args, InvokeOptions? opts = null)
}

The following arguments are supported:

Location string

Specifies the location in which to query for versions.

IncludePreview bool

Should Preview versions of Kubernetes in AKS be included? Defaults to true

VersionPrefix string

A prefix filter for the versions of Kubernetes which should be returned; for example 1. will return 1.9 to 1.14, whereas 1.12 will return 1.12.2.

Location string

Specifies the location in which to query for versions.

IncludePreview bool

Should Preview versions of Kubernetes in AKS be included? Defaults to true

VersionPrefix string

A prefix filter for the versions of Kubernetes which should be returned; for example 1. will return 1.9 to 1.14, whereas 1.12 will return 1.12.2.

location string

Specifies the location in which to query for versions.

includePreview boolean

Should Preview versions of Kubernetes in AKS be included? Defaults to true

versionPrefix string

A prefix filter for the versions of Kubernetes which should be returned; for example 1. will return 1.9 to 1.14, whereas 1.12 will return 1.12.2.

location str

Specifies the location in which to query for versions.

include_preview bool

Should Preview versions of Kubernetes in AKS be included? Defaults to true

version_prefix str

A prefix filter for the versions of Kubernetes which should be returned; for example 1. will return 1.9 to 1.14, whereas 1.12 will return 1.12.2.

GetKubernetesServiceVersions Result

The following output properties are available:

Id string

The provider-assigned unique ID for this managed resource.

LatestVersion string

The most recent version available. If include_preview == false, this is the most recent non-preview version available.

Location string
Versions List<string>

The list of all supported versions.

IncludePreview bool
VersionPrefix string
Id string

The provider-assigned unique ID for this managed resource.

LatestVersion string

The most recent version available. If include_preview == false, this is the most recent non-preview version available.

Location string
Versions []string

The list of all supported versions.

IncludePreview bool
VersionPrefix string
id string

The provider-assigned unique ID for this managed resource.

latestVersion string

The most recent version available. If include_preview == false, this is the most recent non-preview version available.

location string
versions string[]

The list of all supported versions.

includePreview boolean
versionPrefix string
id str

The provider-assigned unique ID for this managed resource.

latest_version str

The most recent version available. If include_preview == false, this is the most recent non-preview version available.

location str
versions List[str]

The list of all supported versions.

include_preview bool
version_prefix str

Package Details

Repository
https://github.com/pulumi/pulumi-azure
License
Apache-2.0
Notes
This Pulumi package is based on the azurerm Terraform Provider.