-
Notifications
You must be signed in to change notification settings - Fork 378
Update mi test mi for region lock sfi #5538
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
Open
RyAuld
wants to merge
4
commits into
main
Choose a base branch
from
Update-MI-Test-MI-For-Region-Lock-SFI
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+17
−18
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
10c45e1
Update managed identity references to new MI
RyAuld 93d9cd2
Consolidate Key Vault UAMI into main UAMI
RyAuld 529ff1f
Fix E2E IMDS tests to use ID4SMSIHostedAgent pool's managed identity
RyAuld 0aa48a9
Fix SAMI test to specify client ID when multiple UAMIs exist
RyAuld File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to pass null here so we can test SAMI.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ran into the issue below when using Null and having Multiple resources assigned. Is there a way to specify without breaking the null test?
Managed Identity E2E Test Pool Configuration Issue
Problem: The ID4SMSIHostedAgent pool had multiple User Assigned Managed Identities (UAMIs) configured:
Legacy cross-subscription LabVaultAccess_UAMI (4b7a4b0b-ecb2-409e-879a-1e21a15ddaf6)
New local ID4SMSIHostedAgent_UAMI (8ef2ae5a-f349-4d36-bc0e-a567f2cc50f7)
Error: When the E2E test attempted to use System Assigned Managed Identity (SAMI) with null client ID, the Azure IMDS service returned:
Status: BadRequest
"Multiple user assigned identities exist, please specify the clientId / resourceId of the identity in the token request"
Root Cause: Azure's Instance Metadata Service (IMDS) requires explicit identity specification when multiple UAMIs are assigned to a resource. The test's SAMI approach (using null/default) became ambiguous.
Solution: Modified the E2E test to explicitly specify the local UAMI's client ID (8ef2ae5a-f349-4d36-bc0e-a567f2cc50f7) instead of relying on default SAMI behavior.
Why This Approach:
Maintains backward compatibility for main branch builds that depend on the legacy UAMI
Avoids infrastructure changes that could impact other test pools or pipelines
Provides explicit identity specification, eliminating ambiguity
Ensures all test cases use the correct local UAMI that the pool has proper access to