Deploy a Linux-based Spark cluster in Azure HDInsight
{"type": "microsoft.hdinsight/clusters", "apiversion": "2018-06-01-preview", "name": "[parameters('clustername')]", "location": "[parameters('location')]", "properties": {"clusterversion": "4.0", "ostype": "linux", "tier": "standard", "clusterdefinition": {"kind": "spark", "configurations": {"gateway": {"restauthcredential.isenabled": true, "restauthcredential.username": "[parameters('clusterloginusername')]", "restauthcredential.password": "[parameters('clusterloginpassword')]"}}}, "storageprofile": {"storageaccounts": [{"name": "[replace(replace(reference(resourceid('microsoft.storage/storageaccounts", format('storage{0}", uniquestring(resourcegroup().id)))).primaryendpoints.blob, "https://", "'), "/", "')]", "isdefault": true, "container": "[parameters('clustername')]", "key": "[listkeys(resourceid('microsoft.storage/storageaccounts", format('storage{0}", uniquestring(resourcegroup().id))), "2021-04-01').keys[0].value]"}]}, "computeprofile": {"roles": [{"name": "headnode", "targetinstancecount": 2, "hardwareprofile": {"vmsize": "[parameters('headnodevirtualmachinesize')]"}, "osprofile": {"linuxoperatingsystemprofile": {"username": "[parameters('sshusername')]", "password": "[parameters('sshpassword')]"}}}, {"name": "workernode", "targetinstancecount": 2, "hardwareprofile": {"vmsize": "[parameters('workernodevirtualmachinesize')]"}, "osprofile": {"linuxoperatingsystemprofile": {"username": "[parameters('sshusername')]", "password": "[parameters('sshpassword')]"}}}]}}, "dependson": ["[resourceid('microsoft.storage/storageaccounts", format('storage{0}", uniquestring(resourcegroup().id)))]"]} 