jenkinsci / azure-credentials-plugin

Jenkins Azure Credentials plugin
https://plugins.jenkins.io/azure-credentials/
MIT License
10 stars 26 forks source link

Add support for Azure US Government #215

Closed mpatalon closed 1 year ago

mpatalon commented 1 year ago

Currently the azure-credentials-plugin and azure-keyvault-plugin do not support Azure US Government environment. Any try ends up with "AADSTS900382: Confidential Client is not supported in Cross Cloud" error.

The fix is required in the following plugins:

Changes

Setting authorityHost on ClientSecretCredentialBuilder object. The authorityHost is taken from azureCredential.

Related issues

Testing done

There is no automated test for this specific scenario.

Manual test

This change was manually tested with conjunction with fix for azure-keyvault-plugin.

Prerequisites
Scenario
### Submitter checklist
- [x] Make sure you are opening from a **topic/feature/bugfix branch** (right side) and not your main branch!
- [x] Ensure that the pull request title represents the desired changelog entry
- [x] Please describe what you did
- [x] Link to relevant issues in GitHub or Jira
- [x] Link to relevant pull requests, esp. upstream and downstream changes
- [x] Ensure you have provided tests - that demonstrates feature works or fixes the issue