Skip to content

Instantly share code, notes, and snippets.

@ChabaOk
Created November 9, 2017 15:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ChabaOk/5057f267c9854c2d7e2c4d533f460e91 to your computer and use it in GitHub Desktop.
Save ChabaOk/5057f267c9854c2d7e2c4d533f460e91 to your computer and use it in GitHub Desktop.
Login-AzureRmAccount
$MyKeyVaultName = 'vm360degreekeyvault'
$mySecretPasswordDB = 'passworddb'
New-AzureRmKeyVault -VaultName $MyKeyVaultName -ResourceGroupName 'rgWestUS2' -Location 'westus2'
Get-AzureRmKeyVault -VaultName $MyKeyVaultName
Set-AzureKeyVaultSecret -VaultName $MyKeyVaultName -Name 'passworddb' `
-SecretValue (ConvertTo-SecureString -String 'p@ssw0rd' -AsPlainText -Force)
get-AzureKeyVaultSecret -VaultName $MyKeyVaultName -Name $mySecretPasswordDB | fl *
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment