Cluster Args
The cluster resource API Version: 2020-03-01.
Example Usage
Put a cluster with maximum parameters
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var cluster = new AzureNative.ServiceFabric.Cluster("cluster", new()
{
AddOnFeatures = new[]
{
"RepairManager",
"DnsService",
"BackupRestoreService",
"ResourceMonitorService",
},
ApplicationTypeVersionsCleanupPolicy = new AzureNative.ServiceFabric.Inputs.ApplicationTypeVersionsCleanupPolicyArgs
{
MaxUnusedVersionsToKeep = 2,
},
AzureActiveDirectory = new AzureNative.ServiceFabric.Inputs.AzureActiveDirectoryArgs
{
ClientApplication = "d151ad89-4bce-4ae8-b3d1-1dc79679fa75",
ClusterApplication = "5886372e-7bf4-4878-a497-8098aba608ae",
TenantId = "6abcc6a0-8666-43f1-87b8-172cf86a9f9c",
},
CertificateCommonNames = new AzureNative.ServiceFabric.Inputs.ServerCertificateCommonNamesArgs
{
CommonNames = new[]
{
new AzureNative.ServiceFabric.Inputs.ServerCertificateCommonNameArgs
{
CertificateCommonName = "abc.com",
CertificateIssuerThumbprint = "12599211F8F14C90AFA9532AD79A6F2CA1C00622",
},
},
X509StoreName = "My",
},
ClientCertificateCommonNames = new[]
{
new AzureNative.ServiceFabric.Inputs.ClientCertificateCommonNameArgs
{
CertificateCommonName = "abc.com",
CertificateIssuerThumbprint = "5F3660C715EBBDA31DB1FFDCF508302348DE8E7A",
IsAdmin = true,
},
},
ClientCertificateThumbprints = new[]
{
new AzureNative.ServiceFabric.Inputs.ClientCertificateThumbprintArgs
{
CertificateThumbprint = "5F3660C715EBBDA31DB1FFDCF508302348DE8E7A",
IsAdmin = true,
},
},
ClusterCodeVersion = "7.0.470.9590",
ClusterName = "myCluster",
DiagnosticsStorageAccountConfig = new AzureNative.ServiceFabric.Inputs.DiagnosticsStorageAccountConfigArgs
{
BlobEndpoint = "https://diag.blob.core.windows.net/",
ProtectedAccountKeyName = "StorageAccountKey1",
QueueEndpoint = "https://diag.queue.core.windows.net/",
StorageAccountName = "diag",
TableEndpoint = "https://diag.table.core.windows.net/",
},
EventStoreServiceEnabled = true,
FabricSettings = new[]
{
new AzureNative.ServiceFabric.Inputs.SettingsSectionDescriptionArgs
{
Name = "UpgradeService",
Parameters = new[]
{
new AzureNative.ServiceFabric.Inputs.SettingsParameterDescriptionArgs
{
Name = "AppPollIntervalInSeconds",
Value = "60",
},
},
},
},
Location = "eastus",
ManagementEndpoint = "https://myCluster.eastus.cloudapp.azure.com:19080",
NodeTypes = new[]
{
new AzureNative.ServiceFabric.Inputs.NodeTypeDescriptionArgs
{
ApplicationPorts = new AzureNative.ServiceFabric.Inputs.EndpointRangeDescriptionArgs
{
EndPort = 30000,
StartPort = 20000,
},
ClientConnectionEndpointPort = 19000,
DurabilityLevel = "Bronze",
EphemeralPorts = new AzureNative.ServiceFabric.Inputs.EndpointRangeDescriptionArgs
{
EndPort = 64000,
StartPort = 49000,
},
HttpGatewayEndpointPort = 19007,
IsPrimary = true,
Name = "nt1vm",
VmInstanceCount = 5,
},
},
ReliabilityLevel = "Silver",
ResourceGroupName = "resRg",
ReverseProxyCertificateCommonNames = new AzureNative.ServiceFabric.Inputs.ServerCertificateCommonNamesArgs
{
CommonNames = new[]
{
new AzureNative.ServiceFabric.Inputs.ServerCertificateCommonNameArgs
{
CertificateCommonName = "abc.com",
CertificateIssuerThumbprint = "12599211F8F14C90AFA9532AD79A6F2CA1C00622",
},
},
X509StoreName = "My",
},
Tags = null,
UpgradeDescription = new AzureNative.ServiceFabric.Inputs.ClusterUpgradePolicyArgs
{
DeltaHealthPolicy = new AzureNative.ServiceFabric.Inputs.ClusterUpgradeDeltaHealthPolicyArgs
{
ApplicationDeltaHealthPolicies =
{
{ "fabric:/myApp1", new AzureNative.ServiceFabric.Inputs.ApplicationDeltaHealthPolicyArgs
{
DefaultServiceTypeDeltaHealthPolicy = new AzureNative.ServiceFabric.Inputs.ServiceTypeDeltaHealthPolicyArgs
{
MaxPercentDeltaUnhealthyServices = 0,
},
ServiceTypeDeltaHealthPolicies =
{
{ "myServiceType1", new AzureNative.ServiceFabric.Inputs.ServiceTypeDeltaHealthPolicyArgs
{
MaxPercentDeltaUnhealthyServices = 0,
} },
},
} },
},
MaxPercentDeltaUnhealthyApplications = 0,
MaxPercentDeltaUnhealthyNodes = 0,
MaxPercentUpgradeDomainDeltaUnhealthyNodes = 0,
},
ForceRestart = false,
HealthCheckRetryTimeout = "00:05:00",
HealthCheckStableDuration = "00:00:30",
HealthCheckWaitDuration = "00:00:30",
HealthPolicy = new AzureNative.ServiceFabric.Inputs.ClusterHealthPolicyArgs
{
ApplicationHealthPolicies =
{
{ "fabric:/myApp1", new AzureNative.ServiceFabric.Inputs.ApplicationHealthPolicyArgs
{
DefaultServiceTypeHealthPolicy = new AzureNative.ServiceFabric.Inputs.ServiceTypeHealthPolicyArgs
{
MaxPercentUnhealthyServices = 0,
},
ServiceTypeHealthPolicies =
{
{ "myServiceType1", new AzureNative.ServiceFabric.Inputs.ServiceTypeHealthPolicyArgs
{
MaxPercentUnhealthyServices = 100,
} },
},
} },
},
MaxPercentUnhealthyApplications = 0,
MaxPercentUnhealthyNodes = 0,
},
UpgradeDomainTimeout = "00:15:00",
UpgradeReplicaSetCheckTimeout = "00:10:00",
UpgradeTimeout = "01:00:00",
},
UpgradeMode = "Manual",
VmImage = "Windows",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.azurenative.servicefabric.Cluster;
import com.pulumi.azurenative.servicefabric.ClusterArgs;
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 cluster = new Cluster("cluster", ClusterArgs.builder()
.addOnFeatures(
"RepairManager",
"DnsService",
"BackupRestoreService",
"ResourceMonitorService")
.applicationTypeVersionsCleanupPolicy(Map.of("maxUnusedVersionsToKeep", 2))
.azureActiveDirectory(Map.ofEntries(
Map.entry("clientApplication", "d151ad89-4bce-4ae8-b3d1-1dc79679fa75"),
Map.entry("clusterApplication", "5886372e-7bf4-4878-a497-8098aba608ae"),
Map.entry("tenantId", "6abcc6a0-8666-43f1-87b8-172cf86a9f9c")
))
.certificateCommonNames(Map.ofEntries(
Map.entry("commonNames", Map.ofEntries(
Map.entry("certificateCommonName", "abc.com"),
Map.entry("certificateIssuerThumbprint", "12599211F8F14C90AFA9532AD79A6F2CA1C00622")
)),
Map.entry("x509StoreName", "My")
))
.clientCertificateCommonNames(Map.ofEntries(
Map.entry("certificateCommonName", "abc.com"),
Map.entry("certificateIssuerThumbprint", "5F3660C715EBBDA31DB1FFDCF508302348DE8E7A"),
Map.entry("isAdmin", true)
))
.clientCertificateThumbprints(Map.ofEntries(
Map.entry("certificateThumbprint", "5F3660C715EBBDA31DB1FFDCF508302348DE8E7A"),
Map.entry("isAdmin", true)
))
.clusterCodeVersion("7.0.470.9590")
.clusterName("myCluster")
.diagnosticsStorageAccountConfig(Map.ofEntries(
Map.entry("blobEndpoint", "https://diag.blob.core.windows.net/"),
Map.entry("protectedAccountKeyName", "StorageAccountKey1"),
Map.entry("queueEndpoint", "https://diag.queue.core.windows.net/"),
Map.entry("storageAccountName", "diag"),
Map.entry("tableEndpoint", "https://diag.table.core.windows.net/")
))
.eventStoreServiceEnabled(true)
.fabricSettings(Map.ofEntries(
Map.entry("name", "UpgradeService"),
Map.entry("parameters", Map.ofEntries(
Map.entry("name", "AppPollIntervalInSeconds"),
Map.entry("value", "60")
))
))
.location("eastus")
.managementEndpoint("https://myCluster.eastus.cloudapp.azure.com:19080")
.nodeTypes(Map.ofEntries(
Map.entry("applicationPorts", Map.ofEntries(
Map.entry("endPort", 30000),
Map.entry("startPort", 20000)
)),
Map.entry("clientConnectionEndpointPort", 19000),
Map.entry("durabilityLevel", "Bronze"),
Map.entry("ephemeralPorts", Map.ofEntries(
Map.entry("endPort", 64000),
Map.entry("startPort", 49000)
)),
Map.entry("httpGatewayEndpointPort", 19007),
Map.entry("isPrimary", true),
Map.entry("name", "nt1vm"),
Map.entry("vmInstanceCount", 5)
))
.reliabilityLevel("Silver")
.resourceGroupName("resRg")
.reverseProxyCertificateCommonNames(Map.ofEntries(
Map.entry("commonNames", Map.ofEntries(
Map.entry("certificateCommonName", "abc.com"),
Map.entry("certificateIssuerThumbprint", "12599211F8F14C90AFA9532AD79A6F2CA1C00622")
)),
Map.entry("x509StoreName", "My")
))
.tags()
.upgradeDescription(Map.ofEntries(
Map.entry("deltaHealthPolicy", Map.ofEntries(
Map.entry("applicationDeltaHealthPolicies", Map.of("fabric:/myApp1", Map.ofEntries(
Map.entry("defaultServiceTypeDeltaHealthPolicy", Map.of("maxPercentDeltaUnhealthyServices", 0)),
Map.entry("serviceTypeDeltaHealthPolicies", Map.of("myServiceType1", Map.of("maxPercentDeltaUnhealthyServices", 0)))
))),
Map.entry("maxPercentDeltaUnhealthyApplications", 0),
Map.entry("maxPercentDeltaUnhealthyNodes", 0),
Map.entry("maxPercentUpgradeDomainDeltaUnhealthyNodes", 0)
)),
Map.entry("forceRestart", false),
Map.entry("healthCheckRetryTimeout", "00:05:00"),
Map.entry("healthCheckStableDuration", "00:00:30"),
Map.entry("healthCheckWaitDuration", "00:00:30"),
Map.entry("healthPolicy", Map.ofEntries(
Map.entry("applicationHealthPolicies", Map.of("fabric:/myApp1", Map.ofEntries(
Map.entry("defaultServiceTypeHealthPolicy", Map.of("maxPercentUnhealthyServices", 0)),
Map.entry("serviceTypeHealthPolicies", Map.of("myServiceType1", Map.of("maxPercentUnhealthyServices", 100)))
))),
Map.entry("maxPercentUnhealthyApplications", 0),
Map.entry("maxPercentUnhealthyNodes", 0)
)),
Map.entry("upgradeDomainTimeout", "00:15:00"),
Map.entry("upgradeReplicaSetCheckTimeout", "00:10:00"),
Map.entry("upgradeTimeout", "01:00:00")
))
.upgradeMode("Manual")
.vmImage("Windows")
.build());
}
}
Put a cluster with minimum parameters
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AzureNative = Pulumi.AzureNative;
return await Deployment.RunAsync(() =>
{
var cluster = new AzureNative.ServiceFabric.Cluster("cluster", new()
{
ClusterName = "myCluster",
DiagnosticsStorageAccountConfig = new AzureNative.ServiceFabric.Inputs.DiagnosticsStorageAccountConfigArgs
{
BlobEndpoint = "https://diag.blob.core.windows.net/",
ProtectedAccountKeyName = "StorageAccountKey1",
QueueEndpoint = "https://diag.queue.core.windows.net/",
StorageAccountName = "diag",
TableEndpoint = "https://diag.table.core.windows.net/",
},
FabricSettings = new[]
{
new AzureNative.ServiceFabric.Inputs.SettingsSectionDescriptionArgs
{
Name = "UpgradeService",
Parameters = new[]
{
new AzureNative.ServiceFabric.Inputs.SettingsParameterDescriptionArgs
{
Name = "AppPollIntervalInSeconds",
Value = "60",
},
},
},
},
Location = "eastus",
ManagementEndpoint = "http://myCluster.eastus.cloudapp.azure.com:19080",
NodeTypes = new[]
{
new AzureNative.ServiceFabric.Inputs.NodeTypeDescriptionArgs
{
ApplicationPorts = new AzureNative.ServiceFabric.Inputs.EndpointRangeDescriptionArgs
{
EndPort = 30000,
StartPort = 20000,
},
ClientConnectionEndpointPort = 19000,
DurabilityLevel = "Bronze",
EphemeralPorts = new AzureNative.ServiceFabric.Inputs.EndpointRangeDescriptionArgs
{
EndPort = 64000,
StartPort = 49000,
},
HttpGatewayEndpointPort = 19007,
IsPrimary = true,
Name = "nt1vm",
VmInstanceCount = 5,
},
},
ReliabilityLevel = "Silver",
ResourceGroupName = "resRg",
Tags = null,
UpgradeMode = "Automatic",
});
});
package main
import (
servicefabric "github.com/pulumi/pulumi-azure-native-sdk/servicefabric"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := servicefabric.NewCluster(ctx, "cluster", &servicefabric.ClusterArgs{
ClusterName: pulumi.String("myCluster"),
DiagnosticsStorageAccountConfig: &servicefabric.DiagnosticsStorageAccountConfigArgs{
BlobEndpoint: pulumi.String("https://diag.blob.core.windows.net/"),
ProtectedAccountKeyName: pulumi.String("StorageAccountKey1"),
QueueEndpoint: pulumi.String("https://diag.queue.core.windows.net/"),
StorageAccountName: pulumi.String("diag"),
TableEndpoint: pulumi.String("https://diag.table.core.windows.net/"),
},
FabricSettings: []servicefabric.SettingsSectionDescriptionArgs{
{
Name: pulumi.String("UpgradeService"),
Parameters: servicefabric.SettingsParameterDescriptionArray{
{
Name: pulumi.String("AppPollIntervalInSeconds"),
Value: pulumi.String("60"),
},
},
},
},
Location: pulumi.String("eastus"),
ManagementEndpoint: pulumi.String("http://myCluster.eastus.cloudapp.azure.com:19080"),
NodeTypes: []servicefabric.NodeTypeDescriptionArgs{
{
ApplicationPorts: {
EndPort: pulumi.Int(30000),
StartPort: pulumi.Int(20000),
},
ClientConnectionEndpointPort: pulumi.Int(19000),
DurabilityLevel: pulumi.String("Bronze"),
EphemeralPorts: {
EndPort: pulumi.Int(64000),
StartPort: pulumi.Int(49000),
},
HttpGatewayEndpointPort: pulumi.Int(19007),
IsPrimary: pulumi.Bool(true),
Name: pulumi.String("nt1vm"),
VmInstanceCount: pulumi.Int(5),
},
},
ReliabilityLevel: pulumi.String("Silver"),
ResourceGroupName: pulumi.String("resRg"),
Tags: nil,
UpgradeMode: pulumi.String("Automatic"),
})
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.azurenative.servicefabric.Cluster;
import com.pulumi.azurenative.servicefabric.ClusterArgs;
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 cluster = new Cluster("cluster", ClusterArgs.builder()
.clusterName("myCluster")
.diagnosticsStorageAccountConfig(Map.ofEntries(
Map.entry("blobEndpoint", "https://diag.blob.core.windows.net/"),
Map.entry("protectedAccountKeyName", "StorageAccountKey1"),
Map.entry("queueEndpoint", "https://diag.queue.core.windows.net/"),
Map.entry("storageAccountName", "diag"),
Map.entry("tableEndpoint", "https://diag.table.core.windows.net/")
))
.fabricSettings(Map.ofEntries(
Map.entry("name", "UpgradeService"),
Map.entry("parameters", Map.ofEntries(
Map.entry("name", "AppPollIntervalInSeconds"),
Map.entry("value", "60")
))
))
.location("eastus")
.managementEndpoint("http://myCluster.eastus.cloudapp.azure.com:19080")
.nodeTypes(Map.ofEntries(
Map.entry("applicationPorts", Map.ofEntries(
Map.entry("endPort", 30000),
Map.entry("startPort", 20000)
)),
Map.entry("clientConnectionEndpointPort", 19000),
Map.entry("durabilityLevel", "Bronze"),
Map.entry("ephemeralPorts", Map.ofEntries(
Map.entry("endPort", 64000),
Map.entry("startPort", 49000)
)),
Map.entry("httpGatewayEndpointPort", 19007),
Map.entry("isPrimary", true),
Map.entry("name", "nt1vm"),
Map.entry("vmInstanceCount", 5)
))
.reliabilityLevel("Silver")
.resourceGroupName("resRg")
.tags()
.upgradeMode("Automatic")
.build());
}
}
Import
An existing resource can be imported using its type token, name, and identifier, e.g.
$ pulumi import azure-native:servicefabric:Cluster myCluster /subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/resRg/providers/Microsoft.ServiceFabric/clusters/myCluster
Constructors
Properties
The list of add-on features to enable in the cluster.
The policy used to clean up unused versions.
The AAD authentication settings of the cluster.
The certificate to use for securing the cluster. The certificate provided will be used for node to node security within the cluster, SSL certificate for cluster management endpoint and default admin client.
Describes a list of server certificates referenced by common name that are used to secure the cluster.
The list of client certificates referenced by common name that are allowed to manage the cluster.
The list of client certificates referenced by thumbprint that are allowed to manage the cluster.
The Service Fabric runtime version of the cluster. This property can only by set the user when upgradeMode is set to 'Manual'. To get list of available Service Fabric versions for new clusters use ./ClusterVersion.md. To get the list of available version for existing clusters use availableClusterVersions.
The name of the cluster resource.
The storage account information for storing Service Fabric diagnostic logs.
Indicates if the event store service is enabled.
The list of custom fabric settings to configure the cluster.
The http management endpoint of the cluster.
The list of node types in the cluster.
The reliability level sets the replica set size of system services. Learn about ReliabilityLevel.
The name of the resource group.
The server certificate used by reverse proxy.
Describes a list of server certificates referenced by common name that are used to secure the cluster.
The policy to use when upgrading the cluster.
The upgrade mode of the cluster when new Service Fabric runtime version is available.