Repository navigation
Conversation
Add an "azure" registration authType so a managed cluster can register with the hub using an Azure AD (Entra ID) identity instead of a client certificate, as proposed in enhancements#196. Klusterlet (spoke): RegistrationDriver gains an optional azure field (AzureAuth). credential explicitly selects one of four mechanisms - managed-identity-credential, environment-credential-secret, environment-credential-certificate or workload-identity-credential - with no fallback between them. CEL rules enforce each credential's required fields: clientID for workload identity, clientID and tenantID for both environment credentials, federatedTokenFile only with workload identity, and an azure block whenever authType is azure. Secret material is intentionally not part of the API. Integration tests cover each CEL rule on create and update, including explicitly empty and absent values sent as raw requests. ClusterManager (hub): RegistrationDriverHub gains an optional azure field (AzureConfig) with autoApprovedIdentityPatterns, matched against a joining cluster's Azure AD object ID, and oidcIssuerURL, for hub apiservers that trust Azure AD as a generic OIDC issuer. All additions are optional; existing Klusterlet and ClusterManager resources are unaffected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: ssijbabu <ssijbabu@gmail.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: ssijbabu The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (8)
Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 1 remain after this review. WalkthroughThe API types and CRD schemas add Azure registration settings for Klusterlet and ClusterManager resources. Integration tests cover Azure credential validation, persistence, updates, and ClusterManager configuration. ChangesAzure registration
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~20 minutes Change: Feature Suggested reviewers: Merge Risk: ⚪ Minimal · up to The Azure API changes have no identified issue requiring a fix before merge. Normal checks remain appropriate. Security Architecture ReviewSecurity architecture risk: 🟡 Moderate · up to The new Azure registration settings cross an authentication and approval boundary. The API validates credential choices, but the registration implementation needed to verify identity and enforce approval is not part of this change. No exploitable behavior is established by the reviewed code. Retained concerns
Security review detailsSecurity Blast Radius
Security Findings and Attack Paths
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 6 files. (2 skipped: 2 unsupported.)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Adds the API types for the
azureregistration driver proposed in enhancements#196 (ocm#1676), letting a managed cluster register with the hub using an Azure AD (Entra ID) identity instead of a client certificate.registrationDriver.azure(AzureAuth).credentialselects one of four Azure credential types; CEL rules enforce the fields each one requires. No secret material is part of the API.registrationDrivers[].azure(AzureConfig) withautoApprovedIdentityPatternsandoidcIssuerURL.All new fields are optional, so existing resources are unaffected. Integration tests cover the validation rules.
The ocm implementation using these types is in draft PR ocm#1715, which depends on this one.
Summary by CodeRabbit