-
Notifications
You must be signed in to change notification settings - Fork 558
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: vault_azure_access_credentials with validate_creds provides bad credentials intermittently #2079
Comments
Unfortunately, this is a known issue with Azure since it is eventually consistent. We are looking into ways of solving this but for now we have no way of ensuring the credentials are propagated across all Azure data centers. |
We have observed that service principal credentials propagate throughout the Azure data centers faster than application credentials, which leads to less delays and consistency issues. If possible a workaround would be to always use dynamic service principles i.e. don't provide application_object_id but instead use azure_roles when creating the Role in Vault. |
We're currently using pre-created service principals, because dynamic service principals don't work with API calls for Azure AD (only Azure RM). References: |
Terraform Core Version
1.6.3
Terraform Vault Provider Version
3.21.0
Vault Server Version
1.15.0
Affected Resource(s)
Expected Behavior
The credentials returned by
vault_azure_access_credentials
should be guranteed to be working ifvalidate_creds
is set to `true.Actual Behavior
The credentials fail intermittently and we often need to retry the plan or apply to get it to work. It fails interminenttly when used with the azuread and azurerm providers.
Relevant Error/Panic Output Snippet
Terraform Configuration Files
Steps to Reproduce
Debug Output
No response
Panic Output
No response
Important Factoids
No response
References
No response
Would you like to implement a fix?
None
The text was updated successfully, but these errors were encountered: