Skip to content

ARO-24037: add assign/action to MSI mock role for ACR pull MI support#6005

Open
twolff-gh wants to merge 2 commits into
Azure:mainfrom
twolff-gh:acr-pull-mock-role
Open

ARO-24037: add assign/action to MSI mock role for ACR pull MI support#6005
twolff-gh wants to merge 2 commits into
Azure:mainfrom
twolff-gh:acr-pull-mock-role

Conversation

@twolff-gh

@twolff-gh twolff-gh commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

ARO-24037

What

Add Microsoft.ManagedIdentity/userAssignedIdentities/assign/action to the dev-msi-mock custom role in both mock-identities.bicep (personal dev) and e2e-subscription-rbac-assignment-subscription.bicep (CI e2e subscriptions).

Why

ARO-24037 adds customer-provided managed identities for ACR image pulls. CAPZ needs assign/action to attach these MIs to worker VMs. A backend validation controller verifies this permission via CheckAccess. Without this role update, that check fails in dev/test because the mock MSI role doesn't include the permission.

This is the same permission granted by the Managed Identity Operator built-in role in production.

Testing

No tests — this is a role definition change in bicep. Verified by deploying the mock role update and confirming the backend validation controller's CheckAccess passes.

Special notes for your reviewer

PR Checklist

  • PR is scoped to a single task (no mixed concerns)
  • Title follows Conventional Commits format
  • Summary explains the "Why" behind the change
  • Linked to relevant ticket/issue
  • Screenshots included (if graph/UI/metrics changes)
  • Self-reviewed the diff
  • CI/CD checks are passing (ignore Tide)
  • Draft PR used for WIP (if applicable)
  • Commit history is clean (rebased/squashed)
  • Tricky code blocks are commented
  • Specific reviewers tagged
  • All comment threads resolved before merge

…-24037)

CAPZ needs `Microsoft.ManagedIdentity/userAssignedIdentities/assign/action`
to attach customer-provided ACR pull managed identities to worker VMs.
Add this permission to the mock MSI role in both personal dev and CI e2e
subscription RBAC files so the backend validation controller's CheckAccess
check passes in dev/test environments.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@openshift-ci

openshift-ci Bot commented Jul 9, 2026

Copy link
Copy Markdown

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@twolff-gh twolff-gh marked this pull request as ready for review July 9, 2026 17:15
Copilot AI review requested due to automatic review settings July 9, 2026 17:15
@openshift-ci openshift-ci Bot requested review from geoberle and weherdh July 9, 2026 17:15
@twolff-gh

Copy link
Copy Markdown
Collaborator Author

@roivaz

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the dev/test “MSI mock” custom role definitions to include the Microsoft.ManagedIdentity/userAssignedIdentities/assign/action permission required for CAPZ to attach customer-provided user-assigned managed identities (e.g., ACR pull) to worker VMs, so backend CheckAccess validation succeeds in non-prod environments.

Changes:

  • Add Microsoft.ManagedIdentity/userAssignedIdenties/assign/action to the mock MSI custom role in the personal-dev deployment template.
  • Add the same permission to the per-subscription E2E RBAC template used for CI customer subscriptions.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
dev-infrastructure/templates/mock-identities.bicep Adds assign/action to the dev MSI mock custom role actions list (with inline rationale comment).
dev-infrastructure/templates/e2e-subscription-rbac-assignment-subscription.bicep Adds assign/action to the E2E subscription-scoped MSI mock role definition.

Comment thread dev-infrastructure/templates/mock-identities.bicep
The previous commit missed the third copy of the dev-msi-mock role in
mock-identity-roles.bicep, which would cause role drift depending on
which template is deployed.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings July 9, 2026 21:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

@twolff-gh

Copy link
Copy Markdown
Collaborator Author

/retest

@bennerv

bennerv commented Jul 10, 2026

Copy link
Copy Markdown
Member

/lgtm
/approve

@openshift-ci

openshift-ci Bot commented Jul 10, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bennerv, twolff-gh

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

/retest-required

Remaining retests: 0 against base HEAD 2776c19 and 2 for PR HEAD e5a169f in total

@openshift-ci

openshift-ci Bot commented Jul 11, 2026

Copy link
Copy Markdown

@twolff-gh: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-parallel e5a169f link true /test e2e-parallel

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants