|
98 | 98 |
|
99 | 99 | {{site.base_gateway}} uses the client token retrieved in the authentication step to call the Read Secret API and retrieve the secret value. The request varies depending on the secrets engine version you're using. |
100 | 100 | {{site.base_gateway}} will parse the response of the read secret API automatically and return the secret value. |
| 101 | + - q: Can Azure Key Vault be used with a proxy? |
| 102 | + a: | |
| 103 | + {% new_in 3.12 %} Yes. Azure Vault supports proxy configuration using either environment variables or client constructor arguments. |
| 104 | +
|
| 105 | + **Environment Variables** |
| 106 | +
|
| 107 | + ```sh |
| 108 | + export AZURE_HTTP_PROXY=http://proxy.example.com:8080 |
| 109 | + export AZURE_HTTPS_PROXY=http://proxy.example.com:8080 |
| 110 | + export AZURE_NO_PROXY=localhost,127.0.0.1,.local |
| 111 | + export AZURE_AUTH_USERNAME=proxyuser |
| 112 | + export AZURE_AUTH_PASSWORD=proxypass |
| 113 | + ``` |
| 114 | +
|
| 115 | + **Constructor Arguments** |
| 116 | +
|
| 117 | + ```lua |
| 118 | + local azure_client = require("resty.azure"):new({ |
| 119 | + tenant_id = "tenant-uuid", |
| 120 | + client_id = "app-registration-client-id", |
| 121 | + client_secret = "app-registration-client-secret", |
| 122 | + http_proxy = "http://proxy.example.com:8080", |
| 123 | + https_proxy = "http://proxy.example.com:8080", |
| 124 | + no_proxy = "localhost,127.0.0.1,.local", |
| 125 | + auth_username = "proxyuser", |
| 126 | + auth_password = "proxypass", |
| 127 | + }) |
| 128 | + ``` |
| 129 | + |
| 130 | + {:.info} |
| 131 | + > **Notes:** |
| 132 | + > * Constructor arguments take precedence over environment variables. |
| 133 | + > * When `auth_username` and `auth_password` are provided, they will be automatically converted to a Basic authentication header for both HTTP and HTTPS proxy authorization. |
101 | 134 |
|
102 | 135 | tools: |
103 | 136 | - admin-api |
|
0 commit comments