insomnia-plugin-azure-keyvault-secrets
v1.2.0
Published
An Insomnia plugin to get secrets from Azure Key Vault
Downloads
1,133
Maintainers
Readme
If you like this plugin, leave it a :star: on Github!
Azure Key Vault Secrets for Insomnia
A plugin for Insomnia to retrieve secrets from Azure Key Vault and use them in your environment.
This plugin installs a template tag to read secrets from a Azure Key Vault.
Prerequisites
- Install the Azure Cli and login with
az login
. The plugin will automaticlaly read the cached credentials.
Installation
You can find the plugin at this link.
How to use it
- Install the plugin from the Insomnia plugin Hub.
- Add an environment variable with the name
AZURE_KEYVAULT
, only the name will do, the plugin will create the full url. For example if the full key vault url ishttps://my-key-vault-name.vault.azure.net
, the variable will be"AZURE_KEYVAULT": "my-key-vault-name"
.
- Hit
Ctrl + Space
in any place where an environment variable is available and pickAzure Key Vault Secret
- The template tag will become red indicating an error, in fact it requires a secret name, click on it
- Set the secret name
The live preview will show the value. Click Done.
- The template tag shows now the secret name
Notes
The secrets are retrieved once and cached for the lifetime of the application because Insomnia evaluates all environment variables and template tags very often. To force the retrieval of the secrets simply restart Insomnia.
Usage behind company firewall
If you need to inject local trusted certificates into the plugin, you can do so by setting the AZURE_KEYVAULT_CA_CERT
environment variable to the path of the certificate file. See PR