azure logo
Azure Classic v5.39.0, Apr 1 23

azure.stack.HciCluster

Manages an Azure Stack HCI Cluster.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Azure = Pulumi.Azure;
using AzureAD = Pulumi.AzureAD;

return await Deployment.RunAsync(() => 
{
    var exampleApplication = AzureAD.GetApplication.Invoke(new()
    {
        DisplayName = "Allowed resource types",
    });

    var current = Azure.Core.GetClientConfig.Invoke();

    var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new()
    {
        Location = "West Europe",
    });

    var exampleHciCluster = new Azure.Stack.HciCluster("exampleHciCluster", new()
    {
        ResourceGroupName = exampleResourceGroup.Name,
        Location = exampleResourceGroup.Location,
        ClientId = exampleApplication.Apply(getApplicationResult => getApplicationResult.ApplicationId),
        TenantId = current.Apply(getClientConfigResult => getClientConfigResult.TenantId),
    });

});
package main

import (
	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/stack"
	"github.com/pulumi/pulumi-azuread/sdk/v5/go/azuread"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		exampleApplication, err := azuread.LookupApplication(ctx, &azuread.LookupApplicationArgs{
			DisplayName: pulumi.StringRef("Allowed resource types"),
		}, nil)
		if err != nil {
			return err
		}
		current, err := core.GetClientConfig(ctx, nil, nil)
		if err != nil {
			return err
		}
		exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
			Location: pulumi.String("West Europe"),
		})
		if err != nil {
			return err
		}
		_, err = stack.NewHciCluster(ctx, "exampleHciCluster", &stack.HciClusterArgs{
			ResourceGroupName: exampleResourceGroup.Name,
			Location:          exampleResourceGroup.Location,
			ClientId:          *pulumi.String(exampleApplication.ApplicationId),
			TenantId:          *pulumi.String(current.TenantId),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azuread.AzureadFunctions;
import com.pulumi.azuread.inputs.GetApplicationArgs;
import com.pulumi.azure.core.CoreFunctions;
import com.pulumi.azure.core.ResourceGroup;
import com.pulumi.azure.core.ResourceGroupArgs;
import com.pulumi.azure.stack.HciCluster;
import com.pulumi.azure.stack.HciClusterArgs;
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 exampleApplication = AzureadFunctions.getApplication(GetApplicationArgs.builder()
            .displayName("Allowed resource types")
            .build());

        final var current = CoreFunctions.getClientConfig();

        var exampleResourceGroup = new ResourceGroup("exampleResourceGroup", ResourceGroupArgs.builder()        
            .location("West Europe")
            .build());

        var exampleHciCluster = new HciCluster("exampleHciCluster", HciClusterArgs.builder()        
            .resourceGroupName(exampleResourceGroup.name())
            .location(exampleResourceGroup.location())
            .clientId(exampleApplication.applyValue(getApplicationResult -> getApplicationResult.applicationId()))
            .tenantId(current.applyValue(getClientConfigResult -> getClientConfigResult.tenantId()))
            .build());

    }
}
import pulumi
import pulumi_azure as azure
import pulumi_azuread as azuread

example_application = azuread.get_application(display_name="Allowed resource types")
current = azure.core.get_client_config()
example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
example_hci_cluster = azure.stack.HciCluster("exampleHciCluster",
    resource_group_name=example_resource_group.name,
    location=example_resource_group.location,
    client_id=example_application.application_id,
    tenant_id=current.tenant_id)
import * as pulumi from "@pulumi/pulumi";
import * as azure from "@pulumi/azure";
import * as azuread from "@pulumi/azuread";

const exampleApplication = azuread.getApplication({
    displayName: "Allowed resource types",
});
const current = azure.core.getClientConfig({});
const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
const exampleHciCluster = new azure.stack.HciCluster("exampleHciCluster", {
    resourceGroupName: exampleResourceGroup.name,
    location: exampleResourceGroup.location,
    clientId: exampleApplication.then(exampleApplication => exampleApplication.applicationId),
    tenantId: current.then(current => current.tenantId),
});
resources:
  exampleResourceGroup:
    type: azure:core:ResourceGroup
    properties:
      location: West Europe
  exampleHciCluster:
    type: azure:stack:HciCluster
    properties:
      resourceGroupName: ${exampleResourceGroup.name}
      location: ${exampleResourceGroup.location}
      clientId: ${exampleApplication.applicationId}
      tenantId: ${current.tenantId}
variables:
  exampleApplication:
    fn::invoke:
      Function: azuread:getApplication
      Arguments:
        displayName: Allowed resource types
  current:
    fn::invoke:
      Function: azure:core:getClientConfig
      Arguments: {}

Create HciCluster Resource

new HciCluster(name: string, args: HciClusterArgs, opts?: CustomResourceOptions);
@overload
def HciCluster(resource_name: str,
               opts: Optional[ResourceOptions] = None,
               client_id: Optional[str] = None,
               location: Optional[str] = None,
               name: Optional[str] = None,
               resource_group_name: Optional[str] = None,
               tags: Optional[Mapping[str, str]] = None,
               tenant_id: Optional[str] = None)
@overload
def HciCluster(resource_name: str,
               args: HciClusterArgs,
               opts: Optional[ResourceOptions] = None)
func NewHciCluster(ctx *Context, name string, args HciClusterArgs, opts ...ResourceOption) (*HciCluster, error)
public HciCluster(string name, HciClusterArgs args, CustomResourceOptions? opts = null)
public HciCluster(String name, HciClusterArgs args)
public HciCluster(String name, HciClusterArgs args, CustomResourceOptions options)
type: azure:stack:HciCluster
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args HciClusterArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
args HciClusterArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args HciClusterArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args HciClusterArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args HciClusterArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

HciCluster Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

The HciCluster resource accepts the following input properties:

ClientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ResourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Tags Dictionary<string, string>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

TenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ClientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ResourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Tags map[string]string

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

TenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId String

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName String

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

location String

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name String

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

tags Map<String,String>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId String

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

tags {[key: string]: string}

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

client_id str

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resource_group_name str

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

location str

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name str

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

tags Mapping[str, str]

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenant_id str

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId String

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName String

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

location String

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name String

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

tags Map<String>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId String

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Outputs

All input properties are implicitly available as output properties. Additionally, the HciCluster resource produces the following output properties:

Id string

The provider-assigned unique ID for this managed resource.

Id string

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

id string

The provider-assigned unique ID for this managed resource.

id str

The provider-assigned unique ID for this managed resource.

id String

The provider-assigned unique ID for this managed resource.

Look up Existing HciCluster Resource

Get an existing HciCluster resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: HciClusterState, opts?: CustomResourceOptions): HciCluster
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        client_id: Optional[str] = None,
        location: Optional[str] = None,
        name: Optional[str] = None,
        resource_group_name: Optional[str] = None,
        tags: Optional[Mapping[str, str]] = None,
        tenant_id: Optional[str] = None) -> HciCluster
func GetHciCluster(ctx *Context, name string, id IDInput, state *HciClusterState, opts ...ResourceOption) (*HciCluster, error)
public static HciCluster Get(string name, Input<string> id, HciClusterState? state, CustomResourceOptions? opts = null)
public static HciCluster get(String name, Output<String> id, HciClusterState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
The following state arguments are supported:
ClientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ResourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Tags Dictionary<string, string>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

TenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ClientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

ResourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

Tags map[string]string

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

TenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId String

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

location String

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name String

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName String

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

tags Map<String,String>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId String

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId string

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

location string

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name string

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName string

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

tags {[key: string]: string}

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId string

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

client_id str

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

location str

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name str

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resource_group_name str

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

tags Mapping[str, str]

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenant_id str

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

clientId String

The Client ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

location String

The Azure Region where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

name String

The name which should be used for this Azure Stack HCI Cluster. Changing this forces a new resource to be created.

resourceGroupName String

The name of the Resource Group where the Azure Stack HCI Cluster should exist. Changing this forces a new resource to be created.

tags Map<String>

A mapping of tags which should be assigned to the Azure Stack HCI Cluster.

tenantId String

The Tenant ID of the Azure Active Directory which is used by the Azure Stack HCI Cluster. Changing this forces a new resource to be created.

Import

Azure Stack HCI Clusters can be imported using the resource id, e.g.

 $ pulumi import azure:stack/hciCluster:HciCluster example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.AzureStackHCI/clusters/cluster1

Package Details

Repository
Azure Classic pulumi/pulumi-azure
License
Apache-2.0
Notes

This Pulumi package is based on the azurerm Terraform Provider.