AzureStack-QuickStart-Templ.../101-vm-linux-create-passwor...
WiseMack a3b903769c Create vm create linux with secret from keyvault (#409)
* Create azuredeploy.json

Making a version to use with linux

* Create azuredeploy.parameters.json

* Create metadata.json

* Create README.md

* Update azuredeploy.json

* Update README.md

* Update azuredeploy.json

* Update azuredeploy.json

* Update azuredeploy.json
2019-06-13 14:20:53 -07:00
..
README.md Create vm create linux with secret from keyvault (#409) 2019-06-13 14:20:53 -07:00
azuredeploy.json Create vm create linux with secret from keyvault (#409) 2019-06-13 14:20:53 -07:00
azuredeploy.parameters.json Create vm create linux with secret from keyvault (#409) 2019-06-13 14:20:53 -07:00
metadata.json Create vm create linux with secret from keyvault (#409) 2019-06-13 14:20:53 -07:00

README.md

Very simple deployment of a Linux VM

This template allows you to deploy a simple Linux VM by retrieving the password that is stored in a Key Vault. Therefore the password is never put in plain text in the template parameter file.

Add Secret to the Key Vault

You can add the password to the Key Vault using the below commands:

PowerShell

$Secret = ConvertTo-SecureString -String 'Password' -AsPlainText -Force
Set-AzureKeyVaultSecret -VaultName 'Contoso' -Name 'ITSecret' -SecretValue $Secret

CLI

azure keyvault secret set --vault-name Contoso --secret-name ITSecret --value azurepass

Enable Key Vault for VM and Template secret access

After this you'll need to enable the Key Vault for template deployment. You can do this using the following commands:

PowerShell

Set-AzureRmKeyVaultAccessPolicy -VaultName Contoso -EnabledForTemplateDeployment

CLI

azure keyvault set-policy --vault-name Contoso --enabled-for-template-deployment true