有没有办法让 App Services 设置使用 Key Vault 机密?

Is there a way to have App Services settings use Key Vault secrets?

所以我们已经开始使用 Azure Key Vault 来存储我们的秘密,但看起来像应用程序 运行 因为 Azure 应用服务必须在门户中硬编码应用程序设置值。有没有办法让应用服务中的应用程序设置从 Key Vault 中提取?

Yes you can。通过将应用程序设置值保存为 azure keyvault 参考。

@Microsoft.KeyVault(SecretUri=https://myvault.vault.azure.net/secrets/mysecret/ec96f02080254f109c51a1f14cdb1931)

请注意,您的应用应该具有可以使用托管服务标识 (MSI) 设置的访问权限

其他选项是当您使用 .net 时,您可以 use extension 读取设置