hashicorp / vault-plugin-secrets-azure

Vault Azure Secrets plugin
Mozilla Public License 2.0
26 stars 20 forks source link

Advice on readiness of credentials #187

Open shaneseaton opened 5 months ago

shaneseaton commented 5 months ago

Hi,

When the credentials are created. It takes a while for the credentials to be usable in Azure, something to do with their eventual consistency model.

I was wondering if you provide any advice here on the best way to check when the credential are ready for use?

I have in the past just used a while loop to call the API I need and if I get auth errors keep looping for up to 2 mins before giving up. I can live with this, but wondering if there is a better way.

Also wondering if there is a generic API endpoint I could use in a function like "wait_til_ready()" that calls that API in loop like above and then we know when the creds are ready for use.... or is this not possible because creds might be ready for say listing resources, but not ready in AAD for accessing group members (etc).

Thoughts would be appreciated.

Thanks, Shane.