com.pulumi.azurenative.kubernetes.ConnectedCluster Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azurenative.kubernetes;
import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.kubernetes.ConnectedClusterArgs;
import com.pulumi.azurenative.kubernetes.outputs.ConnectedClusterIdentityResponse;
import com.pulumi.azurenative.kubernetes.outputs.SystemDataResponse;
import com.pulumi.core.Alias;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Optional;
import javax.annotation.Nullable;
/**
* Represents a connected cluster.
* Azure REST API version: 2022-05-01-preview. Prior API version in Azure Native 1.x: 2021-03-01.
*
* Other available API versions: 2020-01-01-preview, 2022-10-01-preview, 2023-11-01-preview, 2024-01-01, 2024-02-01-preview, 2024-06-01-preview, 2024-07-01-preview, 2024-07-15-preview, 2024-12-01-preview.
*
* ## Example Usage
* ### CreateClusterExample
*
*
* {@code
* package generated_program;
*
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.kubernetes.ConnectedCluster;
* import com.pulumi.azurenative.kubernetes.ConnectedClusterArgs;
* import com.pulumi.azurenative.kubernetes.inputs.ConnectedClusterIdentityArgs;
* 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) {
* var connectedCluster = new ConnectedCluster("connectedCluster", ConnectedClusterArgs.builder()
* .agentPublicKeyCertificate("MIICYzCCAcygAwIBAgIBADANBgkqhkiG9w0BAQUFADAuMQswCQYDVQQGEwJVUzEMMAoGA1UEChMDSUJNMREwDwYDVQQLEwhMb2NhbCBDQTAeFw05OTEyMjIwNTAwMDBaFw0wMDEyMjMwNDU5NTlaMC4xCzAJBgNVBAYTAlVTMQwwCgYDVQQKEwNJQk0xETAPBgNVBAsTCExvY2FsIENBMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQD2bZEo7xGaX2/0GHkrNFZvlxBou9v1Jmt/PDiTMPve8r9FeJAQ0QdvFST/0JPQYD20rH0bimdDLgNdNynmyRoS2S/IInfpmf69iyc2G0TPyRvmHIiOZbdCd+YBHQi1adkj17NDcWj6S14tVurFX73zx0sNoMS79q3tuXKrDsxeuwIDAQABo4GQMIGNMEsGCVUdDwGG+EIBDQQ+EzxHZW5lcmF0ZWQgYnkgdGhlIFNlY3VyZVdheSBTZWN1cml0eSBTZXJ2ZXIgZm9yIE9TLzM5MCAoUkFDRikwDgYDVR0PAQH/BAQDAgAGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFJ3+ocRyCTJw067dLSwr/nalx6YMMA0GCSqGSIb3DQEBBQUAA4GBAMaQzt+zaj1GU77yzlr8iiMBXgdQrwsZZWJo5exnAucJAEYQZmOfyLiM D6oYq+ZnfvM0n8G/Y79q8nhwvuxpYOnRSAXFp6xSkrIOeZtJMY1h00LKp/JX3Ng1svZ2agE126JHsQ0bhzN5TKsYfbwfTwfjdWAGy6Vf1nYi/rO+ryMO")
* .clusterName("testCluster")
* .identity(ConnectedClusterIdentityArgs.builder()
* .type("SystemAssigned")
* .build())
* .location("East US")
* .resourceGroupName("k8sc-rg")
* .tags()
* .build());
*
* }
* }
*
* }
*
* ### CreateClusterPrivateLinkExample
*
*
* {@code
* package generated_program;
*
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.kubernetes.ConnectedCluster;
* import com.pulumi.azurenative.kubernetes.ConnectedClusterArgs;
* import com.pulumi.azurenative.kubernetes.inputs.ConnectedClusterIdentityArgs;
* 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) {
* var connectedCluster = new ConnectedCluster("connectedCluster", ConnectedClusterArgs.builder()
* .agentPublicKeyCertificate("MIICYzCCAcygAwIBAgIBADANBgkqhkiG9w0BAQUFADAuMQswCQYDVQQGEwJVUzEMMAoGA1UEChMDSUJNMREwDwYDVQQLEwhMb2NhbCBDQTAeFw05OTEyMjIwNTAwMDBaFw0wMDEyMjMwNDU5NTlaMC4xCzAJBgNVBAYTAlVTMQwwCgYDVQQKEwNJQk0xETAPBgNVBAsTCExvY2FsIENBMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQD2bZEo7xGaX2/0GHkrNFZvlxBou9v1Jmt/PDiTMPve8r9FeJAQ0QdvFST/0JPQYD20rH0bimdDLgNdNynmyRoS2S/IInfpmf69iyc2G0TPyRvmHIiOZbdCd+YBHQi1adkj17NDcWj6S14tVurFX73zx0sNoMS79q3tuXKrDsxeuwIDAQABo4GQMIGNMEsGCVUdDwGG+EIBDQQ+EzxHZW5lcmF0ZWQgYnkgdGhlIFNlY3VyZVdheSBTZWN1cml0eSBTZXJ2ZXIgZm9yIE9TLzM5MCAoUkFDRikwDgYDVR0PAQH/BAQDAgAGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFJ3+ocRyCTJw067dLSwr/nalx6YMMA0GCSqGSIb3DQEBBQUAA4GBAMaQzt+zaj1GU77yzlr8iiMBXgdQrwsZZWJo5exnAucJAEYQZmOfyLiM D6oYq+ZnfvM0n8G/Y79q8nhwvuxpYOnRSAXFp6xSkrIOeZtJMY1h00LKp/JX3Ng1svZ2agE126JHsQ0bhzN5TKsYfbwfTwfjdWAGy6Vf1nYi/rO+ryMO")
* .clusterName("testClusterPvtLink")
* .identity(ConnectedClusterIdentityArgs.builder()
* .type("SystemAssigned")
* .build())
* .location("East US")
* .privateLinkScopeResourceId("/subscriptions/{subscriptionId}/resourceGroups/myResourceGroup/providers/Microsoft.HybridCompute/privateLinkScopes/privateLinkScopeName")
* .privateLinkState("Enabled")
* .resourceGroupName("k8sc-rg")
* .tags()
* .build());
*
* }
* }
*
* }
*
*
* ## Import
*
* An existing resource can be imported using its type token, name, and identifier, e.g.
*
* ```sh
* $ pulumi import azure-native:kubernetes:ConnectedCluster connectedCluster1 /subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Kubernetes/connectedClusters/{clusterName}
* ```
*
*/
@ResourceType(type="azure-native:kubernetes:ConnectedCluster")
public class ConnectedCluster extends com.pulumi.resources.CustomResource {
/**
* Base64 encoded public certificate used by the agent to do the initial handshake to the backend services in Azure.
*
*/
@Export(name="agentPublicKeyCertificate", refs={String.class}, tree="[0]")
private Output agentPublicKeyCertificate;
/**
* @return Base64 encoded public certificate used by the agent to do the initial handshake to the backend services in Azure.
*
*/
public Output agentPublicKeyCertificate() {
return this.agentPublicKeyCertificate;
}
/**
* Version of the agent running on the connected cluster resource
*
*/
@Export(name="agentVersion", refs={String.class}, tree="[0]")
private Output agentVersion;
/**
* @return Version of the agent running on the connected cluster resource
*
*/
public Output agentVersion() {
return this.agentVersion;
}
/**
* Represents the connectivity status of the connected cluster.
*
*/
@Export(name="connectivityStatus", refs={String.class}, tree="[0]")
private Output connectivityStatus;
/**
* @return Represents the connectivity status of the connected cluster.
*
*/
public Output connectivityStatus() {
return this.connectivityStatus;
}
/**
* The Kubernetes distribution running on this connected cluster.
*
*/
@Export(name="distribution", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> distribution;
/**
* @return The Kubernetes distribution running on this connected cluster.
*
*/
public Output> distribution() {
return Codegen.optional(this.distribution);
}
/**
* The identity of the connected cluster.
*
*/
@Export(name="identity", refs={ConnectedClusterIdentityResponse.class}, tree="[0]")
private Output identity;
/**
* @return The identity of the connected cluster.
*
*/
public Output identity() {
return this.identity;
}
/**
* The infrastructure on which the Kubernetes cluster represented by this connected cluster is running on.
*
*/
@Export(name="infrastructure", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> infrastructure;
/**
* @return The infrastructure on which the Kubernetes cluster represented by this connected cluster is running on.
*
*/
public Output> infrastructure() {
return Codegen.optional(this.infrastructure);
}
/**
* The Kubernetes version of the connected cluster resource
*
*/
@Export(name="kubernetesVersion", refs={String.class}, tree="[0]")
private Output kubernetesVersion;
/**
* @return The Kubernetes version of the connected cluster resource
*
*/
public Output kubernetesVersion() {
return this.kubernetesVersion;
}
/**
* Time representing the last instance when heart beat was received from the cluster
*
*/
@Export(name="lastConnectivityTime", refs={String.class}, tree="[0]")
private Output lastConnectivityTime;
/**
* @return Time representing the last instance when heart beat was received from the cluster
*
*/
public Output lastConnectivityTime() {
return this.lastConnectivityTime;
}
/**
* The geo-location where the resource lives
*
*/
@Export(name="location", refs={String.class}, tree="[0]")
private Output location;
/**
* @return The geo-location where the resource lives
*
*/
public Output location() {
return this.location;
}
/**
* Expiration time of the managed identity certificate
*
*/
@Export(name="managedIdentityCertificateExpirationTime", refs={String.class}, tree="[0]")
private Output managedIdentityCertificateExpirationTime;
/**
* @return Expiration time of the managed identity certificate
*
*/
public Output managedIdentityCertificateExpirationTime() {
return this.managedIdentityCertificateExpirationTime;
}
/**
* The name of the resource
*
*/
@Export(name="name", refs={String.class}, tree="[0]")
private Output name;
/**
* @return The name of the resource
*
*/
public Output name() {
return this.name;
}
/**
* Connected cluster offering
*
*/
@Export(name="offering", refs={String.class}, tree="[0]")
private Output offering;
/**
* @return Connected cluster offering
*
*/
public Output offering() {
return this.offering;
}
/**
* The resource id of the private link scope this connected cluster is assigned to, if any.
*
*/
@Export(name="privateLinkScopeResourceId", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> privateLinkScopeResourceId;
/**
* @return The resource id of the private link scope this connected cluster is assigned to, if any.
*
*/
public Output> privateLinkScopeResourceId() {
return Codegen.optional(this.privateLinkScopeResourceId);
}
/**
* Property which describes the state of private link on a connected cluster resource.
*
*/
@Export(name="privateLinkState", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> privateLinkState;
/**
* @return Property which describes the state of private link on a connected cluster resource.
*
*/
public Output> privateLinkState() {
return Codegen.optional(this.privateLinkState);
}
/**
* Provisioning state of the connected cluster resource.
*
*/
@Export(name="provisioningState", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> provisioningState;
/**
* @return Provisioning state of the connected cluster resource.
*
*/
public Output> provisioningState() {
return Codegen.optional(this.provisioningState);
}
/**
* Metadata pertaining to creation and last modification of the resource
*
*/
@Export(name="systemData", refs={SystemDataResponse.class}, tree="[0]")
private Output systemData;
/**
* @return Metadata pertaining to creation and last modification of the resource
*
*/
public Output systemData() {
return this.systemData;
}
/**
* Resource tags.
*
*/
@Export(name="tags", refs={Map.class,String.class}, tree="[0,1,1]")
private Output* @Nullable */ Map> tags;
/**
* @return Resource tags.
*
*/
public Output>> tags() {
return Codegen.optional(this.tags);
}
/**
* Number of CPU cores present in the connected cluster resource
*
*/
@Export(name="totalCoreCount", refs={Integer.class}, tree="[0]")
private Output totalCoreCount;
/**
* @return Number of CPU cores present in the connected cluster resource
*
*/
public Output totalCoreCount() {
return this.totalCoreCount;
}
/**
* Number of nodes present in the connected cluster resource
*
*/
@Export(name="totalNodeCount", refs={Integer.class}, tree="[0]")
private Output totalNodeCount;
/**
* @return Number of nodes present in the connected cluster resource
*
*/
public Output totalNodeCount() {
return this.totalNodeCount;
}
/**
* The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
@Export(name="type", refs={String.class}, tree="[0]")
private Output type;
/**
* @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
public Output type() {
return this.type;
}
/**
*
* @param name The _unique_ name of the resulting resource.
*/
public ConnectedCluster(java.lang.String name) {
this(name, ConnectedClusterArgs.Empty);
}
/**
*
* @param name The _unique_ name of the resulting resource.
* @param args The arguments to use to populate this resource's properties.
*/
public ConnectedCluster(java.lang.String name, ConnectedClusterArgs args) {
this(name, args, null);
}
/**
*
* @param name The _unique_ name of the resulting resource.
* @param args The arguments to use to populate this resource's properties.
* @param options A bag of options that control this resource's behavior.
*/
public ConnectedCluster(java.lang.String name, ConnectedClusterArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("azure-native:kubernetes:ConnectedCluster", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false);
}
private ConnectedCluster(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("azure-native:kubernetes:ConnectedCluster", name, null, makeResourceOptions(options, id), false);
}
private static ConnectedClusterArgs makeArgs(ConnectedClusterArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
if (options != null && options.getUrn().isPresent()) {
return null;
}
return args == null ? ConnectedClusterArgs.Empty : args;
}
private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) {
var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
.version(Utilities.getVersion())
.aliases(List.of(
Output.of(Alias.builder().type("azure-native:kubernetes/v20200101preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20210301:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20210401preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20211001:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20220501preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20221001preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20231101preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20240101:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20240201preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20240601preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20240701preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20240715preview:ConnectedCluster").build()),
Output.of(Alias.builder().type("azure-native:kubernetes/v20241201preview:ConnectedCluster").build())
))
.build();
return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id);
}
/**
* Get an existing Host resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @param options Optional settings to control the behavior of the CustomResource.
*/
public static ConnectedCluster get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
return new ConnectedCluster(name, id, options);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy