AzureCluster

An Anthos cluster running on Azure. For more information, see:

Example Usage

Basic_azure_cluster

A basic example of a containerazure azure cluster

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.ContainerFunctions;
import com.pulumi.gcp.container.inputs.GetAzureVersionsArgs;
import com.pulumi.gcp.container.AzureClient;
import com.pulumi.gcp.container.AzureClientArgs;
import com.pulumi.gcp.container.AzureCluster;
import com.pulumi.gcp.container.AzureClusterArgs;
import com.pulumi.gcp.container.inputs.AzureClusterAuthorizationArgs;
import com.pulumi.gcp.container.inputs.AzureClusterControlPlaneArgs;
import com.pulumi.gcp.container.inputs.AzureClusterControlPlaneSshConfigArgs;
import com.pulumi.gcp.container.inputs.AzureClusterFleetArgs;
import com.pulumi.gcp.container.inputs.AzureClusterNetworkingArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var versions = ContainerFunctions.getAzureVersions(GetAzureVersionsArgs.builder()
.location("us-west1")
.project("my-project-name")
.build());
var basic = new AzureClient("basic", AzureClientArgs.builder()
.applicationId("12345678-1234-1234-1234-123456789111")
.location("us-west1")
.project("my-project-name")
.tenantId("12345678-1234-1234-1234-123456789111")
.build());
var primary = new AzureCluster("primary", AzureClusterArgs.builder()
.authorization(AzureClusterAuthorizationArgs.builder()
.adminUsers(AzureClusterAuthorizationAdminUserArgs.builder()
.username("mmv2@google.com")
.build())
.build())
.azureRegion("westus2")
.client(basic.name().applyValue(name -> String.format("projects/my-project-number/locations/us-west1/azureClients/%s", name)))
.controlPlane(AzureClusterControlPlaneArgs.builder()
.sshConfig(AzureClusterControlPlaneSshConfigArgs.builder()
.authorizedKey("ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQC8yaayO6lnb2v+SedxUMa2c8vtIEzCzBjM3EJJsv8Vm9zUDWR7dXWKoNGARUb2mNGXASvI6mFIDXTIlkQ0poDEPpMaXR0g2cb5xT8jAAJq7fqXL3+0rcJhY/uigQ+MrT6s+ub0BFVbsmGHNrMQttXX9gtmwkeAEvj3mra9e5pkNf90qlKnZz6U0SVArxVsLx07vHPHDIYrl0OPG4zUREF52igbBPiNrHJFDQJT/4YlDMJmo/QT/A1D6n9ocemvZSzhRx15/Arjowhr+VVKSbaxzPtEfY0oIg2SrqJnnr/l3Du5qIefwh5VmCZe4xopPUaDDoOIEFriZ88sB+3zz8ib8sk8zJJQCgeP78tQvXCgS+4e5W3TUg9mxjB6KjXTyHIVhDZqhqde0OI3Fy1UuVzRUwnBaLjBnAwP5EoFQGRmDYk/rEYe7HTmovLeEBUDQocBQKT4Ripm/xJkkWY7B07K/tfo56dGUCkvyIVXKBInCh+dLK7gZapnd4UWkY0xBYcwo1geMLRq58iFTLA2j/JmpmHXp7m0l7jJii7d44uD3tTIFYThn7NlOnvhLim/YcBK07GMGIN7XwrrKZKmxXaspw6KBWVhzuw1UPxctxshYEaMLfFg/bwOw8HvMPr9VtrElpSB7oiOh91PDIPdPBgHCi7N2QgQ5l/ZDBHieSpNrQ== thomasrodgers")
.build())
.subnetId("/subscriptions/12345678-1234-1234-1234-123456789111/resourceGroups/my--dev-byo/providers/Microsoft.Network/virtualNetworks/my--dev-vnet/subnets/default")
.version(versions.applyValue(getAzureVersionsResult -> getAzureVersionsResult.validVersions()[0]))
.build())
.fleet(AzureClusterFleetArgs.builder()
.project("my-project-number")
.build())
.location("us-west1")
.networking(AzureClusterNetworkingArgs.builder()
.podAddressCidrBlocks("10.200.0.0/16")
.serviceAddressCidrBlocks("10.32.0.0/24")
.virtualNetworkId("/subscriptions/12345678-1234-1234-1234-123456789111/resourceGroups/my--dev-byo/providers/Microsoft.Network/virtualNetworks/my--dev-vnet")
.build())
.project("my-project-name")
.resourceGroupId("/subscriptions/12345678-1234-1234-1234-123456789111/resourceGroups/my--dev-cluster")
.build());
}
}

Import

Cluster can be imported using any of these accepted formats

$ pulumi import gcp:container/azureCluster:AzureCluster default projects/{{project}}/locations/{{location}}/azureClusters/{{name}}
$ pulumi import gcp:container/azureCluster:AzureCluster default {{project}}/{{location}}/{{name}}
$ pulumi import gcp:container/azureCluster:AzureCluster default {{location}}/{{name}}

Properties

Link copied to clipboard
val annotations: Output<Map<String, String>>?

Optional. Annotations on the cluster. This field has the same restrictions as Kubernetes annotations. The total size of all keys and values combined is limited to 256k. Keys can have 2 segments: prefix (optional) and name (required), separated by a slash (/). Prefix must be a DNS subdomain. Name must be 63 characters or less, begin and end with alphanumerics, with dashes (-), underscores (_), dots (.), and alphanumerics between.

Link copied to clipboard

Configuration related to the cluster RBAC settings.

Link copied to clipboard
val azureRegion: Output<String>

The Azure region where the cluster runs. Each Google Cloud region supports a subset of nearby Azure regions. You can call to list all supported Azure regions within a given Google Cloud region.

Link copied to clipboard
val client: Output<String>

Name of the AzureClient. The AzureClient resource must reside on the same GCP project and region as the AzureCluster. AzureClient names are formatted as projects/<project-number>/locations/<region>/azureClients/<client-id>. See Resource Names (https:cloud.google.com/apis/design/resource_names) for more details on Google Cloud resource names.

Link copied to clipboard

Configuration related to the cluster control plane.

Link copied to clipboard
val createTime: Output<String>

Output only. The time at which this cluster was created.

Link copied to clipboard
val description: Output<String>?

Optional. A human readable description of this cluster. Cannot be longer than 255 UTF-8 encoded bytes.

Link copied to clipboard
val endpoint: Output<String>

Output only. The endpoint of the cluster's API server.

Link copied to clipboard
val etag: Output<String>

Allows clients to perform consistent read-modify-writes through optimistic concurrency control. May be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

Link copied to clipboard

Fleet configuration.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val location: Output<String>

The location for the resource

Link copied to clipboard

(Beta only) Logging configuration.

Link copied to clipboard
val name: Output<String>

The name of this resource.

Link copied to clipboard

Cluster-wide networking configuration.

Link copied to clipboard
val project: Output<String>

The number of the Fleet host project where this cluster will be registered. (Optional) The project for the resource

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val reconciling: Output<Boolean>

Output only. If set, there are currently changes in flight to the cluster.

Link copied to clipboard
val resourceGroupId: Output<String>

The ARM ID of the resource group where the cluster resources are deployed. For example: /subscriptions/*/resourceGroups/* //

Link copied to clipboard
val state: Output<String>

Output only. The current state of the cluster. Possible values: STATE_UNSPECIFIED, PROVISIONING, RUNNING, RECONCILING, STOPPING, ERROR, DEGRADED

Link copied to clipboard
val uid: Output<String>

Output only. A globally unique identifier for the cluster.

Link copied to clipboard
val updateTime: Output<String>

Output only. The time at which this cluster was last updated.

Link copied to clipboard
val urn: Output<String>
Link copied to clipboard

Output only. Workload Identity settings.