You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

858 lines
39 KiB

  1. {
  2. "$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json",
  3. "contentVersion": "1.0.0.0",
  4. "parameters": {
  5. "prefix": {
  6. "type": "string"
  7. },
  8. "clusterLocation": {
  9. "type": "string",
  10. "metadata": {
  11. "description": "Location of the Cluster"
  12. }
  13. },
  14. "clusterName": {
  15. "type": "string",
  16. "defaultValue": "Cluster",
  17. "metadata": {
  18. "description": "Name of your cluster - Between 3 and 23 characters. Letters and numbers only"
  19. }
  20. },
  21. "nt0applicationStartPort": {
  22. "type": "int",
  23. "defaultValue": 20000
  24. },
  25. "nt0applicationEndPort": {
  26. "type": "int",
  27. "defaultValue": 30000
  28. },
  29. "nt0ephemeralStartPort": {
  30. "type": "int",
  31. "defaultValue": 49152
  32. },
  33. "nt0ephemeralEndPort": {
  34. "type": "int",
  35. "defaultValue": 65534
  36. },
  37. "nt0fabricTcpGatewayPort": {
  38. "type": "int",
  39. "defaultValue": 19000
  40. },
  41. "nt0fabricHttpGatewayPort": {
  42. "type": "int",
  43. "defaultValue": 19080
  44. },
  45. "nt0reverseProxyEndpointPort": {
  46. "type": "int",
  47. "defaultValue": 19081
  48. },
  49. "webMvcHttpPort": {
  50. "type": "int",
  51. "defaultValue": 5100
  52. },
  53. "webSpaHttpPort": {
  54. "type": "int",
  55. "defaultValue": 5104
  56. },
  57. "webStatusHttpPort": {
  58. "type": "int",
  59. "defaultValue": 5107
  60. },
  61. "IdSrvHttpRule": {
  62. "type": "int",
  63. "defaultValue": 5105
  64. },
  65. "BasketApiHttpRule": {
  66. "type": "int",
  67. "defaultValue": 5103
  68. },
  69. "CatalogApiHttpRule": {
  70. "type": "int",
  71. "defaultValue": 5101
  72. },
  73. "OrderingApiHttpRule": {
  74. "type": "int",
  75. "defaultValue": 5102
  76. },
  77. "MarketingApiHttpRule": {
  78. "type": "int",
  79. "defaultValue": 5110
  80. },
  81. "LocationsApiHttpRule": {
  82. "type": "int",
  83. "defaultValue": 5109
  84. },
  85. "subnet0Name": {
  86. "type": "string",
  87. "defaultValue": "Subnet-0"
  88. },
  89. "subnet0Prefix": {
  90. "type": "string",
  91. "defaultValue": "10.0.0.0/24"
  92. },
  93. "computeLocation": {
  94. "type": "string"
  95. },
  96. "publicIPAddressName": {
  97. "type": "string",
  98. "defaultValue": "PublicIP-VM"
  99. },
  100. "publicIPAddressType": {
  101. "type": "string",
  102. "allowedValues": [
  103. "Dynamic"
  104. ],
  105. "defaultValue": "Dynamic"
  106. },
  107. "vmStorageAccountContainerName": {
  108. "type": "string",
  109. "defaultValue": "vhds"
  110. },
  111. "adminUserName": {
  112. "type": "string",
  113. "defaultValue": "testadm",
  114. "metadata": {
  115. "description": "Remote desktop user Id"
  116. }
  117. },
  118. "adminPassword": {
  119. "type": "securestring",
  120. "metadata": {
  121. "description": "Remote desktop user password. Must be a strong password"
  122. }
  123. },
  124. "virtualNetworkName": {
  125. "type": "string",
  126. "defaultValue": "VNet"
  127. },
  128. "addressPrefix": {
  129. "type": "string",
  130. "defaultValue": "10.0.0.0/16"
  131. },
  132. "dnsName": {
  133. "type": "string"
  134. },
  135. "nicName": {
  136. "type": "string",
  137. "defaultValue": "NIC"
  138. },
  139. "lbName": {
  140. "type": "string",
  141. "defaultValue": "LoadBalancer"
  142. },
  143. "lbIPName": {
  144. "type": "string",
  145. "defaultValue": "PublicIP-LB-FE"
  146. },
  147. "overProvision": {
  148. "type": "string",
  149. "defaultValue": "false"
  150. },
  151. "vmImagePublisher": {
  152. "type": "string",
  153. "defaultValue": "MicrosoftWindowsServer"
  154. },
  155. "vmImageOffer": {
  156. "type": "string",
  157. "defaultValue": "WindowsServer"
  158. },
  159. "vmImageSku": {
  160. "type": "string",
  161. "defaultValue": "2012-R2-Datacenter"
  162. },
  163. "vmImageVersion": {
  164. "type": "string",
  165. "defaultValue": "latest"
  166. },
  167. "storageAccountType": {
  168. "type": "string",
  169. "allowedValues": [
  170. "Standard_LRS",
  171. "Standard_GRS"
  172. ],
  173. "defaultValue": "Standard_LRS",
  174. "metadata": {
  175. "description": "Replication option for the VM image storage account"
  176. }
  177. },
  178. "supportLogStorageAccountType": {
  179. "type": "string",
  180. "allowedValues": [
  181. "Standard_LRS",
  182. "Standard_GRS"
  183. ],
  184. "defaultValue": "Standard_LRS",
  185. "metadata": {
  186. "description": "Replication option for the support log storage account"
  187. }
  188. },
  189. "supportLogStorageAccountName": {
  190. "type": "string",
  191. "defaultValue": "[toLower( concat('sflogs', uniqueString(resourceGroup().id),'2'))]",
  192. "metadata": {
  193. "description": "Name for the storage account that contains support logs from the cluster"
  194. }
  195. },
  196. "applicationDiagnosticsStorageAccountType": {
  197. "type": "string",
  198. "allowedValues": [
  199. "Standard_LRS",
  200. "Standard_GRS"
  201. ],
  202. "defaultValue": "Standard_LRS",
  203. "metadata": {
  204. "description": "Replication option for the application diagnostics storage account"
  205. }
  206. },
  207. "applicationDiagnosticsStorageAccountName": {
  208. "type": "string",
  209. "defaultValue": "[toLower(concat(uniqueString(resourceGroup().id), '3' ))]",
  210. "metadata": {
  211. "description": "Name for the storage account that contains application diagnostics data from the cluster"
  212. }
  213. },
  214. "nt0InstanceCount": {
  215. "type": "int",
  216. "defaultValue": 1,
  217. "metadata": {
  218. "description": "Instance count for node type"
  219. }
  220. },
  221. "vmNodeType0Name": {
  222. "type": "string",
  223. "defaultValue": "primary",
  224. "maxLength": 9
  225. },
  226. "vmNodeType0Size": {
  227. "type": "string",
  228. "defaultValue": "Standard_D2_v2"
  229. }
  230. },
  231. "variables": {
  232. "vmssApiVersion": "2017-03-30",
  233. "lbApiVersion": "2015-06-15",
  234. "vNetApiVersion": "2015-06-15",
  235. "storageApiVersion": "2016-01-01",
  236. "publicIPApiVersion": "2015-06-15",
  237. "vnetID": "[resourceId('Microsoft.Network/virtualNetworks',parameters('virtualNetworkName'))]",
  238. "subnet0Ref": "[concat(variables('vnetID'),'/subnets/',parameters('subnet0Name'))]",
  239. "lbID0": "[resourceId('Microsoft.Network/loadBalancers', concat('LB','-', variables('clusterName'),'-',parameters('vmNodeType0Name')))]",
  240. "lbIPConfig0": "[concat(variables('lbID0'),'/frontendIPConfigurations/LoadBalancerIPConfig')]",
  241. "lbPoolID0": "[concat(variables('lbID0'),'/backendAddressPools/LoadBalancerBEAddressPool')]",
  242. "lbProbeID0": "[concat(variables('lbID0'),'/probes/FabricGatewayProbe')]",
  243. "lbHttpProbeID0": "[concat(variables('lbID0'),'/probes/FabricHttpGatewayProbe')]",
  244. "lbNatPoolID0": "[concat(variables('lbID0'),'/inboundNatPools/LoadBalancerBEAddressNatPool')]",
  245. "vmStorageAccountName0": "[toLower(concat(uniqueString(resourceGroup().id), '1', '0' ))]",
  246. "supportLogStorageAccountName": "[take(concat(parameters('prefix'), parameters('supportLogStorageAccountName')),22)]",
  247. "applicationDiagnosticsStorageAccountName" : "[take(concat(parameters('prefix'), parameters('applicationDiagnosticsStorageAccountName')),22)]",
  248. "clusterName": "[concat(parameters('prefix'), parameters('clusterName'))]",
  249. "uniqueStringArray0": [
  250. "[concat(variables('vmStorageAccountName0'), '0')]",
  251. "[concat(variables('vmStorageAccountName0'), '1')]",
  252. "[concat(variables('vmStorageAccountName0'), '2')]",
  253. "[concat(variables('vmStorageAccountName0'), '3')]",
  254. "[concat(variables('vmStorageAccountName0'), '4')]"
  255. ]
  256. },
  257. "resources": [
  258. {
  259. "apiVersion": "[variables('storageApiVersion')]",
  260. "type": "Microsoft.Storage/storageAccounts",
  261. "name": "[variables('supportLogStorageAccountName')]",
  262. "location": "[parameters('computeLocation')]",
  263. "dependsOn": [],
  264. "properties": {},
  265. "kind": "Storage",
  266. "sku": {
  267. "name": "[parameters('supportLogStorageAccountType')]"
  268. },
  269. "tags": {
  270. "resourceType": "Service Fabric",
  271. "clusterName": "[variables('clusterName')]"
  272. }
  273. },
  274. {
  275. "apiVersion": "[variables('storageApiVersion')]",
  276. "type": "Microsoft.Storage/storageAccounts",
  277. "name": "[variables('applicationDiagnosticsStorageAccountName')]",
  278. "location": "[parameters('computeLocation')]",
  279. "dependsOn": [],
  280. "properties": {},
  281. "kind": "Storage",
  282. "sku": {
  283. "name": "[parameters('applicationDiagnosticsStorageAccountType')]"
  284. },
  285. "tags": {
  286. "resourceType": "Service Fabric",
  287. "clusterName": "[variables('clusterName')]"
  288. }
  289. },
  290. {
  291. "apiVersion": "[variables('vNetApiVersion')]",
  292. "type": "Microsoft.Network/virtualNetworks",
  293. "name": "[parameters('virtualNetworkName')]",
  294. "location": "[parameters('computeLocation')]",
  295. "dependsOn": [],
  296. "properties": {
  297. "addressSpace": {
  298. "addressPrefixes": [
  299. "[parameters('addressPrefix')]"
  300. ]
  301. },
  302. "subnets": [
  303. {
  304. "name": "[parameters('subnet0Name')]",
  305. "properties": {
  306. "addressPrefix": "[parameters('subnet0Prefix')]"
  307. }
  308. }
  309. ]
  310. },
  311. "tags": {
  312. "resourceType": "Service Fabric",
  313. "clusterName": "[variables('clusterName')]"
  314. }
  315. },
  316. {
  317. "apiVersion": "[variables('publicIPApiVersion')]",
  318. "type": "Microsoft.Network/publicIPAddresses",
  319. "name": "[concat(parameters('lbIPName'),'-','0')]",
  320. "location": "[parameters('computeLocation')]",
  321. "properties": {
  322. "dnsSettings": {
  323. "domainNameLabel": "[parameters('dnsName')]"
  324. },
  325. "publicIPAllocationMethod": "Dynamic"
  326. },
  327. "tags": {
  328. "resourceType": "Service Fabric",
  329. "clusterName": "[variables('clusterName')]"
  330. }
  331. },
  332. {
  333. "apiVersion": "[variables('lbApiVersion')]",
  334. "type": "Microsoft.Network/loadBalancers",
  335. "name": "[concat('LB','-', variables('clusterName'),'-',parameters('vmNodeType0Name'))]",
  336. "location": "[parameters('computeLocation')]",
  337. "dependsOn": [
  338. "[concat('Microsoft.Network/publicIPAddresses/',concat(parameters('lbIPName'),'-','0'))]"
  339. ],
  340. "properties": {
  341. "frontendIPConfigurations": [
  342. {
  343. "name": "LoadBalancerIPConfig",
  344. "properties": {
  345. "publicIPAddress": {
  346. "id": "[resourceId('Microsoft.Network/publicIPAddresses',concat(parameters('lbIPName'),'-','0'))]"
  347. }
  348. }
  349. }
  350. ],
  351. "backendAddressPools": [
  352. {
  353. "name": "LoadBalancerBEAddressPool",
  354. "properties": {}
  355. }
  356. ],
  357. "loadBalancingRules": [
  358. {
  359. "name": "LBRule",
  360. "properties": {
  361. "backendAddressPool": {
  362. "id": "[variables('lbPoolID0')]"
  363. },
  364. "backendPort": "[parameters('nt0fabricTcpGatewayPort')]",
  365. "enableFloatingIP": "false",
  366. "frontendIPConfiguration": {
  367. "id": "[variables('lbIPConfig0')]"
  368. },
  369. "frontendPort": "[parameters('nt0fabricTcpGatewayPort')]",
  370. "idleTimeoutInMinutes": "5",
  371. "probe": {
  372. "id": "[variables('lbProbeID0')]"
  373. },
  374. "protocol": "tcp"
  375. }
  376. },
  377. {
  378. "name": "LBHttpRule",
  379. "properties": {
  380. "backendAddressPool": {
  381. "id": "[variables('lbPoolID0')]"
  382. },
  383. "backendPort": "[parameters('nt0fabricHttpGatewayPort')]",
  384. "enableFloatingIP": "false",
  385. "frontendIPConfiguration": {
  386. "id": "[variables('lbIPConfig0')]"
  387. },
  388. "frontendPort": "[parameters('nt0fabricHttpGatewayPort')]",
  389. "idleTimeoutInMinutes": "5",
  390. "probe": {
  391. "id": "[variables('lbHttpProbeID0')]"
  392. },
  393. "protocol": "tcp"
  394. }
  395. },
  396. {
  397. "name": "ReverseProxyHttpRule",
  398. "properties": {
  399. "backendAddressPool": {
  400. "id": "[variables('lbPoolID0')]"
  401. },
  402. "backendPort": "[parameters('nt0reverseProxyEndpointPort')]",
  403. "enableFloatingIP": "false",
  404. "frontendIPConfiguration": {
  405. "id": "[variables('lbIPConfig0')]"
  406. },
  407. "frontendPort": "[parameters('nt0reverseProxyEndpointPort')]",
  408. "idleTimeoutInMinutes": "5",
  409. "probe": {
  410. "id": "[variables('lbHttpProbeID0')]"
  411. },
  412. "protocol": "tcp"
  413. }
  414. },
  415. {
  416. "name": "WebMVCHttpRule",
  417. "properties": {
  418. "backendAddressPool": {
  419. "id": "[variables('lbPoolID0')]"
  420. },
  421. "backendPort": "[parameters('webMvcHttpPort')]",
  422. "enableFloatingIP": "false",
  423. "frontendIPConfiguration": {
  424. "id": "[variables('lbIPConfig0')]"
  425. },
  426. "frontendPort": "[parameters('webMvcHttpPort')]",
  427. "idleTimeoutInMinutes": "5",
  428. "probe": {
  429. "id": "[variables('lbHttpProbeID0')]"
  430. },
  431. "protocol": "tcp"
  432. }
  433. },
  434. {
  435. "name": "WebSPAHttpRule",
  436. "properties": {
  437. "backendAddressPool": {
  438. "id": "[variables('lbPoolID0')]"
  439. },
  440. "backendPort": "[parameters('webSpaHttpPort')]",
  441. "enableFloatingIP": "false",
  442. "frontendIPConfiguration": {
  443. "id": "[variables('lbIPConfig0')]"
  444. },
  445. "frontendPort": "[parameters('webSpaHttpPort')]",
  446. "idleTimeoutInMinutes": "5",
  447. "probe": {
  448. "id": "[variables('lbHttpProbeID0')]"
  449. },
  450. "protocol": "tcp"
  451. }
  452. },
  453. {
  454. "name": "WebStatusHttpRule",
  455. "properties": {
  456. "backendAddressPool": {
  457. "id": "[variables('lbPoolID0')]"
  458. },
  459. "backendPort": "[parameters('webStatusHttpPort')]",
  460. "enableFloatingIP": "false",
  461. "frontendIPConfiguration": {
  462. "id": "[variables('lbIPConfig0')]"
  463. },
  464. "frontendPort": "[parameters('webStatusHttpPort')]",
  465. "idleTimeoutInMinutes": "5",
  466. "probe": {
  467. "id": "[variables('lbHttpProbeID0')]"
  468. },
  469. "protocol": "tcp"
  470. }
  471. },
  472. {
  473. "name": "IdSrvHttpRule",
  474. "properties": {
  475. "backendAddressPool": {
  476. "id": "[variables('lbPoolID0')]"
  477. },
  478. "backendPort": "[parameters('IdSrvHttpRule')]",
  479. "enableFloatingIP": "false",
  480. "frontendIPConfiguration": {
  481. "id": "[variables('lbIPConfig0')]"
  482. },
  483. "frontendPort": "[parameters('IdSrvHttpRule')]",
  484. "idleTimeoutInMinutes": "5",
  485. "probe": {
  486. "id": "[variables('lbHttpProbeID0')]"
  487. },
  488. "protocol": "tcp"
  489. }
  490. },
  491. {
  492. "name": "BasketApiHttpRule",
  493. "properties": {
  494. "backendAddressPool": {
  495. "id": "[variables('lbPoolID0')]"
  496. },
  497. "backendPort": "[parameters('BasketApiHttpRule')]",
  498. "enableFloatingIP": "false",
  499. "frontendIPConfiguration": {
  500. "id": "[variables('lbIPConfig0')]"
  501. },
  502. "frontendPort": "[parameters('BasketApiHttpRule')]",
  503. "idleTimeoutInMinutes": "5",
  504. "protocol": "tcp"
  505. }
  506. },
  507. {
  508. "name": "CatalogApiHttpRule",
  509. "properties": {
  510. "backendAddressPool": {
  511. "id": "[variables('lbPoolID0')]"
  512. },
  513. "backendPort": "[parameters('CatalogApiHttpRule')]",
  514. "enableFloatingIP": "false",
  515. "frontendIPConfiguration": {
  516. "id": "[variables('lbIPConfig0')]"
  517. },
  518. "frontendPort": "[parameters('CatalogApiHttpRule')]",
  519. "idleTimeoutInMinutes": "5",
  520. "protocol": "tcp"
  521. }
  522. },
  523. {
  524. "name": "OrderingApiHttpRule",
  525. "properties": {
  526. "backendAddressPool": {
  527. "id": "[variables('lbPoolID0')]"
  528. },
  529. "backendPort": "[parameters('OrderingApiHttpRule')]",
  530. "enableFloatingIP": "false",
  531. "frontendIPConfiguration": {
  532. "id": "[variables('lbIPConfig0')]"
  533. },
  534. "frontendPort": "[parameters('OrderingApiHttpRule')]",
  535. "idleTimeoutInMinutes": "5",
  536. "protocol": "tcp"
  537. }
  538. },
  539. {
  540. "name": "MarketingApiHttpRule",
  541. "properties": {
  542. "backendAddressPool": {
  543. "id": "[variables('lbPoolID0')]"
  544. },
  545. "backendPort": "[parameters('MarketingApiHttpRule')]",
  546. "enableFloatingIP": "false",
  547. "frontendIPConfiguration": {
  548. "id": "[variables('lbIPConfig0')]"
  549. },
  550. "frontendPort": "[parameters('MarketingApiHttpRule')]",
  551. "idleTimeoutInMinutes": "5",
  552. "protocol": "tcp"
  553. }
  554. },
  555. {
  556. "name": "LocationsApiHttpRule",
  557. "properties": {
  558. "backendAddressPool": {
  559. "id": "[variables('lbPoolID0')]"
  560. },
  561. "backendPort": "[parameters('LocationsApiHttpRule')]",
  562. "enableFloatingIP": "false",
  563. "frontendIPConfiguration": {
  564. "id": "[variables('lbIPConfig0')]"
  565. },
  566. "frontendPort": "[parameters('LocationsApiHttpRule')]",
  567. "idleTimeoutInMinutes": "5",
  568. "protocol": "tcp"
  569. }
  570. }
  571. ],
  572. "probes": [
  573. {
  574. "name": "FabricGatewayProbe",
  575. "properties": {
  576. "intervalInSeconds": 5,
  577. "numberOfProbes": 2,
  578. "port": "[parameters('nt0fabricTcpGatewayPort')]",
  579. "protocol": "tcp"
  580. }
  581. },
  582. {
  583. "name": "FabricHttpGatewayProbe",
  584. "properties": {
  585. "intervalInSeconds": 5,
  586. "numberOfProbes": 2,
  587. "port": "[parameters('nt0fabricHttpGatewayPort')]",
  588. "protocol": "tcp"
  589. }
  590. }
  591. ],
  592. "inboundNatPools": [
  593. {
  594. "name": "LoadBalancerBEAddressNatPool",
  595. "properties": {
  596. "backendPort": "3389",
  597. "frontendIPConfiguration": {
  598. "id": "[variables('lbIPConfig0')]"
  599. },
  600. "frontendPortRangeEnd": "4500",
  601. "frontendPortRangeStart": "3389",
  602. "protocol": "tcp"
  603. }
  604. }
  605. ]
  606. },
  607. "tags": {
  608. "resourceType": "Service Fabric",
  609. "clusterName": "[variables('clusterName')]"
  610. }
  611. },
  612. {
  613. "apiVersion": "[variables('storageApiVersion')]",
  614. "type": "Microsoft.Storage/storageAccounts",
  615. "name": "[variables('uniqueStringArray0')[copyIndex()]]",
  616. "location": "[parameters('computeLocation')]",
  617. "dependsOn": [],
  618. "properties": {},
  619. "copy": {
  620. "name": "storageLoop",
  621. "count": 5
  622. },
  623. "kind": "Storage",
  624. "sku": {
  625. "name": "[parameters('storageAccountType')]"
  626. },
  627. "tags": {
  628. "resourceType": "Service Fabric",
  629. "clusterName": "[variables('clusterName')]"
  630. }
  631. },
  632. {
  633. "apiVersion": "[variables('vmssApiVersion')]",
  634. "type": "Microsoft.Compute/virtualMachineScaleSets",
  635. "name": "[parameters('vmNodeType0Name')]",
  636. "location": "[parameters('computeLocation')]",
  637. "dependsOn": [
  638. "[concat('Microsoft.Network/virtualNetworks/', parameters('virtualNetworkName'))]",
  639. "[concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[0])]",
  640. "[concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[1])]",
  641. "[concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[2])]",
  642. "[concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[3])]",
  643. "[concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[4])]",
  644. "[concat('Microsoft.Network/loadBalancers/', concat('LB','-', variables('clusterName'),'-',parameters('vmNodeType0Name')))]",
  645. "[concat('Microsoft.Storage/storageAccounts/', variables('supportLogStorageAccountName'))]",
  646. "[concat('Microsoft.Storage/storageAccounts/', variables('applicationDiagnosticsStorageAccountName'))]"
  647. ],
  648. "properties": {
  649. "overprovision": "[parameters('overProvision')]",
  650. "upgradePolicy": {
  651. "mode": "Automatic"
  652. },
  653. "virtualMachineProfile": {
  654. "extensionProfile": {
  655. "extensions": [
  656. {
  657. "name": "[concat(parameters('vmNodeType0Name'),'_ServiceFabricNode')]",
  658. "properties": {
  659. "type": "ServiceFabricNode",
  660. "autoUpgradeMinorVersion": true,
  661. "protectedSettings": {
  662. "StorageAccountKey1": "[listKeys(resourceId('Microsoft.Storage/storageAccounts', variables('supportLogStorageAccountName')),'2015-05-01-preview').key1]",
  663. "StorageAccountKey2": "[listKeys(resourceId('Microsoft.Storage/storageAccounts', variables('supportLogStorageAccountName')),'2015-05-01-preview').key2]"
  664. },
  665. "publisher": "Microsoft.Azure.ServiceFabric",
  666. "settings": {
  667. "clusterEndpoint": "[reference(variables('clusterName')).clusterEndpoint]",
  668. "nodeTypeRef": "[parameters('vmNodeType0Name')]",
  669. "dataPath": "D:\\\\SvcFab",
  670. "durabilityLevel": "Bronze",
  671. "enableParallelJobs": true,
  672. "nicPrefixOverride": "[parameters('subnet0Prefix')]"
  673. },
  674. "typeHandlerVersion": "1.0"
  675. }
  676. },
  677. {
  678. "name": "[concat('VMDiagnosticsVmExt','_vmNodeType0Name')]",
  679. "properties": {
  680. "type": "IaaSDiagnostics",
  681. "autoUpgradeMinorVersion": true,
  682. "protectedSettings": {
  683. "storageAccountName": "[variables('applicationDiagnosticsStorageAccountName')]",
  684. "storageAccountKey": "[listKeys(resourceId('Microsoft.Storage/storageAccounts', variables('applicationDiagnosticsStorageAccountName')),'2015-05-01-preview').key1]",
  685. "storageAccountEndPoint": "https://core.windows.net/"
  686. },
  687. "publisher": "Microsoft.Azure.Diagnostics",
  688. "settings": {
  689. "WadCfg": {
  690. "DiagnosticMonitorConfiguration": {
  691. "overallQuotaInMB": "50000",
  692. "EtwProviders": {
  693. "EtwEventSourceProviderConfiguration": [
  694. {
  695. "provider": "Microsoft-ServiceFabric-Actors",
  696. "scheduledTransferKeywordFilter": "1",
  697. "scheduledTransferPeriod": "PT5M",
  698. "DefaultEvents": {
  699. "eventDestination": "ServiceFabricReliableActorEventTable"
  700. }
  701. },
  702. {
  703. "provider": "Microsoft-ServiceFabric-Services",
  704. "scheduledTransferPeriod": "PT5M",
  705. "DefaultEvents": {
  706. "eventDestination": "ServiceFabricReliableServiceEventTable"
  707. }
  708. }
  709. ],
  710. "EtwManifestProviderConfiguration": [
  711. {
  712. "provider": "cbd93bc2-71e5-4566-b3a7-595d8eeca6e8",
  713. "scheduledTransferLogLevelFilter": "Information",
  714. "scheduledTransferKeywordFilter": "4611686018427387904",
  715. "scheduledTransferPeriod": "PT5M",
  716. "DefaultEvents": {
  717. "eventDestination": "ServiceFabricSystemEventTable"
  718. }
  719. }
  720. ]
  721. }
  722. }
  723. },
  724. "StorageAccount": "[variables('applicationDiagnosticsStorageAccountName')]"
  725. },
  726. "typeHandlerVersion": "1.5"
  727. }
  728. }
  729. ]
  730. },
  731. "networkProfile": {
  732. "networkInterfaceConfigurations": [
  733. {
  734. "name": "[concat(parameters('nicName'), '-0')]",
  735. "properties": {
  736. "ipConfigurations": [
  737. {
  738. "name": "[concat(parameters('nicName'),'-',0)]",
  739. "properties": {
  740. "loadBalancerBackendAddressPools": [
  741. {
  742. "id": "[variables('lbPoolID0')]"
  743. }
  744. ],
  745. "loadBalancerInboundNatPools": [
  746. {
  747. "id": "[variables('lbNatPoolID0')]"
  748. }
  749. ],
  750. "subnet": {
  751. "id": "[variables('subnet0Ref')]"
  752. }
  753. }
  754. }
  755. ],
  756. "primary": true
  757. }
  758. }
  759. ]
  760. },
  761. "osProfile": {
  762. "adminPassword": "[parameters('adminPassword')]",
  763. "adminUsername": "[parameters('adminUsername')]",
  764. "computernamePrefix": "[parameters('vmNodeType0Name')]"
  765. },
  766. "storageProfile": {
  767. "imageReference": {
  768. "publisher": "[parameters('vmImagePublisher')]",
  769. "offer": "[parameters('vmImageOffer')]",
  770. "sku": "[parameters('vmImageSku')]",
  771. "version": "[parameters('vmImageVersion')]"
  772. },
  773. "osDisk": {
  774. "caching": "ReadOnly",
  775. "createOption": "FromImage",
  776. "vhdContainers": [
  777. "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[0]), variables('storageApiVersion')).primaryEndpoints.blob, parameters('vmStorageAccountContainerName'))]",
  778. "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[1]), variables('storageApiVersion')).primaryEndpoints.blob, parameters('vmStorageAccountContainerName'))]",
  779. "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[2]), variables('storageApiVersion')).primaryEndpoints.blob, parameters('vmStorageAccountContainerName'))]",
  780. "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[3]), variables('storageApiVersion')).primaryEndpoints.blob, parameters('vmStorageAccountContainerName'))]",
  781. "[concat(reference(concat('Microsoft.Storage/storageAccounts/', variables('uniqueStringArray0')[4]), variables('storageApiVersion')).primaryEndpoints.blob, parameters('vmStorageAccountContainerName'))]"
  782. ],
  783. "name": "vmssosdisk"
  784. }
  785. }
  786. }
  787. },
  788. "sku": {
  789. "name": "[parameters('vmNodeType0Size')]",
  790. "capacity": "[parameters('nt0InstanceCount')]",
  791. "tier": "Standard"
  792. },
  793. "tags": {
  794. "resourceType": "Service Fabric",
  795. "clusterName": "[variables('clusterName')]"
  796. }
  797. },
  798. {
  799. "apiVersion": "2017-07-01-preview",
  800. "type": "Microsoft.ServiceFabric/clusters",
  801. "name": "[variables('clusterName')]",
  802. "location": "[parameters('clusterLocation')]",
  803. "dependsOn": [
  804. "[concat('Microsoft.Storage/storageAccounts/', variables('supportLogStorageAccountName'))]"
  805. ],
  806. "properties": {
  807. "addonFeatures": [
  808. "DnsService"
  809. ],
  810. "clientCertificateCommonNames": [],
  811. "clientCertificateThumbprints": [],
  812. "clusterCodeVersion": "6.0.232.9494",
  813. "clusterState": "Default",
  814. "diagnosticsStorageAccountConfig": {
  815. "blobEndpoint": "[reference(concat('Microsoft.Storage/storageAccounts/', variables('supportLogStorageAccountName')), variables('storageApiVersion')).primaryEndpoints.blob]",
  816. "protectedAccountKeyName": "StorageAccountKey1",
  817. "queueEndpoint": "[reference(concat('Microsoft.Storage/storageAccounts/', variables('supportLogStorageAccountName')), variables('storageApiVersion')).primaryEndpoints.queue]",
  818. "storageAccountName": "[variables('supportLogStorageAccountName')]",
  819. "tableEndpoint": "[reference(concat('Microsoft.Storage/storageAccounts/', variables('supportLogStorageAccountName')), variables('storageApiVersion')).primaryEndpoints.table]"
  820. },
  821. "fabricSettings": [],
  822. "managementEndpoint": "[concat('http://',reference(concat(parameters('lbIPName'),'-','0')).dnsSettings.fqdn,':',parameters('nt0fabricHttpGatewayPort'))]",
  823. "nodeTypes": [
  824. {
  825. "name": "[parameters('vmNodeType0Name')]",
  826. "applicationPorts": {
  827. "endPort": "[parameters('nt0applicationEndPort')]",
  828. "startPort": "[parameters('nt0applicationStartPort')]"
  829. },
  830. "clientConnectionEndpointPort": "[parameters('nt0fabricTcpGatewayPort')]",
  831. "durabilityLevel": "Bronze",
  832. "ephemeralPorts": {
  833. "endPort": "[parameters('nt0ephemeralEndPort')]",
  834. "startPort": "[parameters('nt0ephemeralStartPort')]"
  835. },
  836. "httpGatewayEndpointPort": "[parameters('nt0fabricHttpGatewayPort')]",
  837. "isPrimary": true,
  838. "reverseProxyEndpointPort": "[parameters('nt0reverseProxyEndpointPort')]",
  839. "vmInstanceCount": "[parameters('nt0InstanceCount')]"
  840. }
  841. ],
  842. "provisioningState": "Default",
  843. "reliabilityLevel": "None",
  844. "upgradeMode": "Manual",
  845. "vmImage": "Windows"
  846. },
  847. "tags": {
  848. "resourceType": "Service Fabric",
  849. "clusterName": "[variables('clusterName')]"
  850. }
  851. }
  852. ],
  853. "outputs": {
  854. "clusterProperties": {
  855. "value": "[reference(variables('clusterName'))]",
  856. "type": "object"
  857. }
  858. }
  859. }