Skip to content

Conversation

@p3ck
Copy link
Collaborator

@p3ck p3ck commented Oct 20, 2025

SUMMARY

By using the AzureRMAuth class we are consistent with how all modules create their credentials.

Also fix inconsistencies with how client_id, secret and tenant are specified.

Fixes: #1777

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

plugins/lookup/azure_keyvault_secret.py
plugins/lookup/azure_service_principal_attribute.py

ADDITIONAL INFORMATION

Now the following wotks by picking up the credentials via the environment variables.

    - name: Set key vault secret fact
      ansible.builtin.set_fact: secretValue={{ lookup('azure.azcollection.azure_keyvault_secret','adminPassword',vault_url=keyvaulturi, use_msi=false) }}

By using the AzureRMAuth class we are consistent with how all modules
create their credentials.

Also fix inconsistencies with how client_id, secret and tenant are
specified.
@p3ck p3ck requested review from Fred-sun and xuzhang3 October 20, 2025 18:18
@p3ck
Copy link
Collaborator Author

p3ck commented Oct 20, 2025

FYI - azure_cloud.get_cloud_from_metadata_endpoint does not exist in azure.cli.core

@zunyangc
Copy link
Collaborator

Hi @magodo, all tests passed, please procced to merge.

@zunyangc
Copy link
Collaborator

Will add test to cover this in pipeline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

azure_keyvault_secret lookup might be broken

2 participants