Skip to content

Commit ce8ece5

Browse files
committed
Add more draft content
1 parent 745d4bf commit ce8ece5

File tree

1 file changed

+72
-84
lines changed

1 file changed

+72
-84
lines changed

articles/service-fabric/quickstart-cluster-template.md

Lines changed: 72 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ Azure Service Fabric is a distributed systems platform that makes it easy to pac
1616

1717
This article describes how to deploy a Service Fabric test cluster in Azure using the Resource Manager. This 5-node Windows cluster is secured with a self-signed certificate and thus only intended for instructional purposes (rather than production workloads).
1818

19+
We'll use Azure PowerShell to deploy the template. In addition to Azure PowerShell, you can also use the Azure portal, Azure CLI, and REST API. To learn other deployment methods, see [Deploy templates](../azure-resource-manager/templates/deploy-portal.md).
20+
1921
If you don't have an Azure subscription, create a [free](https://azure.microsoft.com/free/) account before you begin.
2022

2123
## Prerequisites
@@ -69,119 +71,105 @@ The script will prompt you for the following (be sure to modify *CertDNSName* an
6971

7072
* **Password:** Password!1
7173
* **CertDNSName:** sfquickstart.southcentralus.cloudapp.azure.com
72-
* **KeyVaultName:** SFQuickstartKV0416
74+
* **KeyVaultName:** SFQuickstartKV
7375
* **KeyVaultSecretName:** clustercert
7476

7577
Upon completion, the script will provide the parameter values needed for template deployment. Be sure to store these in the following variables, as they will be needed to deploy your cluster template:
7678

7779
```powershell
78-
$sourceVaultId = ""
79-
$certUrlValue = ""
80-
$certThumbprint = ""
80+
$certThumbprint = "<Certificate Thumbprint>"
81+
$certUrlValue = "<Certificate URL>"
82+
$sourceVaultId = "<Source Vault Resource Id>"
8183
```
8284

8385
## Create a Service Fabric cluster
8486

85-
<!-- The second H2 must start with "Create a". For example, 'Create a Key Vault', 'Create a virtual machine', etc. -->
86-
8787
### Review the template
8888

89-
<!-- The first sentence must be the following sentence. The link is the quickstart template from GitHub. The link must begin with https://github.com/Azure/azure-quickstart-templates/. -->
90-
91-
The template used in this quickstart is from [Azure Quickstart templates]().
92-
93-
<!-- After the first sentence, add a JSON codefence that links to the quickstart template. Customers have provided feedback that they prefer to see the whole template; therefore, we recommend you include the whole template in your article. If your template is too long to show in the quickstart, you can instead add a sentence that says "The template for this article is too long to show here. To view the template, see ..."
94-
95-
The syntax for the codefence is: -->
96-
97-
:::code language="json" source="~/quickstart-templates/<TEMPLATE NAME>/azuredeploy.json" range="000-000" highlight="000-000":::
98-
99-
<!-- After the JSON codefence, a list of each resourceType from the JSON must exist with a link to the template reference starting with /azure/templates. For example:
100-
101-
* [**Microsoft.KeyVault/vaults**](/azure/templates/microsoft.keyvault/vaults): create an Azure key vault.
102-
* [**Microsoft.KeyVault/vaults/secrets**](/azure/templates/microsoft.keyvault/vaults/secrets): create an key vault secret.
103-
104-
The URL usually appears as, for example, https://docs.microsoft.com/en-us/azure/templates/Microsoft.Network/2019-11-01/loadBalancers for loadbalancer of Microsoft.Network. Remove the API version from the URL, the URL redirects the users to the latest version.
105-
-->
106-
107-
* [Azure resource type](link to the template reference)
108-
* [Azure resource type](link to the template reference)
109-
110-
<!-- List additional quickstart templates. For example: [Azure Quickstart Templates](https://azure.microsoft.com/resources/templates/?resourceType=Microsoft.Keyvault&pageNumber=1&sort=Popular).
111-
Notice the resourceType and sort elements in the URL.
112-
-->
89+
The template used in this quickstart is from [Azure Quickstart templates](https://github.com/Azure/azure-quickstart-templates/blob/master/service-fabric-secure-cluster-5-node-1-nodetype). The template for this article is too long to show here. To view the template, see https://github.com/Azure/azure-quickstart-templates/blob/master/service-fabric-secure-cluster-5-node-1-nodetype/azuredeploy.json.
90+
91+
Multiple Azure resources have been defined in the template:
92+
93+
* [Microsoft.Storage/storageAccounts](/azure/templates/microsoft.storage/storageaccounts)
94+
* [Microsoft.Network/virtualNetworks](/azure/templates/microsoft.network/virtualnetworks)
95+
* [Microsoft.Network/publicIPAddresses](/azure/templates/microsoft.network/publicipaddresses)
96+
* [Microsoft.Network/loadBalancers](/azure/templates/microsoft.network/loadbalancers)
97+
* [Microsoft.Compute/virtualMachineScaleSets](/azure/templates/microsoft.compute/virtualmachinescalesets)
98+
* [Microsoft.ServiceFabric/clusters](/azure/templates/microsoft.servicefabric/clusters)
99+
100+
To find more templates that are related to Azure Service Fabric, see
101+
[Azure Quickstart Templates](https://azure.microsoft.com/en-us/resources/templates/?sort=Popular&term=service+fabric).
102+
103+
### Customize the parameters file
104+
105+
Open *azuredeploy.parameters.json* and edit the parameter values so that:
106+
107+
* **clusterName** matches the value you supplied for *CertDNSName* when creating your cluster certificate
108+
* **adminUserName** is some value other than the default *GEN-UNIQUE* token
109+
* **adminPassword** is some value other than the default *GEN-PASSWORD* token
110+
* **certificateThumbprint**, **sourceVaultResourceId**, and **certificateUrlValue** are all empty string (`""`)
111+
112+
For example:
113+
114+
```json
115+
{
116+
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
117+
"contentVersion": "1.0.0.0",
118+
"parameters": {
119+
"clusterName": {
120+
"value": "sfquickstart"
121+
},
122+
"adminUsername": {
123+
"value": "testadm"
124+
},
125+
"adminPassword": {
126+
"value": "Password#1234"
127+
},
128+
"certificateThumbprint": {
129+
"value": ""
130+
},
131+
"sourceVaultResourceId": {
132+
"value": ""
133+
},
134+
"certificateUrlValue": {
135+
"value": ""
136+
}
137+
}
138+
}
139+
```
113140

114141
## Deploy the template
115142

116-
<!--
117-
One of the following options must be included:
118-
119-
- **CLI**: In an Azure CLI Interactive codefence must contain **az group deployment create**. For example:
120-
121-
```azurecli-interactive
122-
read -p "Enter a project name that is used for generating resource names:" projectName &&
123-
read -p "Enter the location (i.e. centralus):" location &&
124-
templateUri="https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-storage-account-create/azuredeploy.json" &&
125-
resourceGroupName="${projectName}rg" &&
126-
az group create --name $resourceGroupName --location "$location" &&
127-
az group deployment create --resource-group $resourceGroupName --template-uri $templateUri
128-
echo "Press [ENTER] to continue ..." &&
129-
read
130-
```
131-
132-
- **PowerShell**: In an Azure PowerShell Interactive codefence must contain **New-AzResourceGroupDeployment**. For example:
143+
Store the paths of your resource manager template and parameter files in variables, then deploy the template.
133144

134-
```azurepowershell-interactive
135-
$projectName = Read-Host -Prompt "Enter a project name that is used for generating resource names"
136-
$location = Read-Host -Prompt "Enter the location (i.e. centralus)"
137-
$templateUri = "https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-storage-account-create/azuredeploy.json"
138-
139-
$resourceGroupName = "${projectName}rg"
140-
141-
New-AzResourceGroup -Name $resourceGroupName -Location "$location"
142-
New-AzResourceGroupDeployment -ResourceGroupName $resourceGroupName -TemplateUri $templateUri
143-
144-
Read-Host -Prompt "Press [ENTER] to continue ..."
145-
146-
For an example, see Add a description. Press tab when you are done.
147-
```
148-
149-
- **Portal**: A button with description **Deploy Resource Manager template to Azure**, with image **/media/<QUICKSTART FILE NAME>/deploy-to-azure.png*, must exist and have a link that starts with **https://portal.azure.com/#create/Microsoft.Template/uri/**:
150-
151-
```markdown
152-
[![Deploy to Azure](./media/quick-create-template/deploy-to-azure.png)](https://portal.azure.com/#create/Microsoft.Template/uri/https%3A%2F%2Fraw.githubusercontent.com%2FAzure%2Fazure-quickstart-templates%2Fmaster%2F101-key-vault-create%2Fazuredeploy.json)
153-
```
154-
155-
To get the standard button image and find more information about this deployment option, see [Use a deployment button to deploy templates from GitHub repository](/azure/azure-resource-manager/templates/deploy-to-azure-button.md).
156-
-->
145+
```powershell
146+
$templateFilePath = "<full path to azuredeploy.json>"
147+
$parameterFilePath = "<full path to azuredeploy.parameters.json>"
148+
149+
New-AzResourceGroupDeployment `
150+
-ResourceGroupName $resourceGroupName `
151+
-TemplateFile $templateFilePath `
152+
-TemplateParameterFile $parameterFilePath `
153+
-CertificateThumbprint $certThumbprint `
154+
-CertificateUrlValue $certUrlValue `
155+
-SourceVaultResourceId $sourceVaultId `
156+
-Verbose
157+
```
157158

158159
## Review deployed resources
159160

160-
<!-- You can also use the title "Validate the deployment"-->
161+
161162

162163
## Clean up resources
163164

164165
When no longer needed, delete the resource group, which deletes the resources in the resource group.
165166

166-
<!--
167-
168-
Choose Azure CLI, Azure PowerShell, or Azure portal to delete the resource group. Use [Zone pivots](https://review.docs.microsoft.com/help/contribute/zone-pivots?branch=master) if you want to use multiple options. Here are the samples for Azure CLI and Azure PowerShell:
169-
170-
```azurecli-interactive
171-
echo "Enter the Resource Group name:" &&
172-
read resourceGroupName &&
173-
az group delete --name $resourceGroupName &&
174-
echo "Press [ENTER] to continue ..."
175-
```
176-
177167
```azurepowershell-interactive
178168
$resourceGroupName = Read-Host -Prompt "Enter the Resource Group name"
179169
Remove-AzResourceGroup -Name $resourceGroupName
180170
Write-Host "Press [ENTER] to continue..."
181171
```
182172

183-
-->
184-
185173
## Next steps
186174

187175
<!-- You can either make the next steps similar to the next steps in your other quickstarts, or point users to the following tutorial.-->

0 commit comments

Comments
 (0)