DevOps Basics: Deploy an Azure Resource Manager template with Visual Studio Team Services

Sign in to queue

The Discussion

  • User profile image

    How can we protect/hide the password? Storing it in code in cleartext is not great practice!

  • User profile image

    @Charles: we can store the password in azure keyvault,

    New-AzureRmKeyVault -VaultName '<name>' -ResourceGroupName '<resource group name>' -Location '<location>'

    $Secret = ConvertTo-SecureString -String '<password>' -AsPlainText -Force

    $secretvalue = Set-AzureKeyVaultSecret -VaultName '<name>' -Name '<secret name>' -SecretValue $Secret

    Set-AzureRmKeyVaultAccessPolicy -VaultName <valut name> -EnabledForTemplateDeployment


    "sqlServerPrimaryAdminPassword": {
    "reference": {
    "keyVault": {
    "id": "<reference ID path>"
    "secretName": "<secret name>"

Add Your 2 Cents