Add AKS Kubernetes RBAC with Microsoft Entra groups quickstart - #496
Conversation
… succeeds Co-authored-by: Rebecca-Calixte <262454636+Rebecca-Calixte@users.noreply.github.com>
…tart Co-authored-by: Rebecca-Calixte <262454636+Rebecca-Calixte@users.noreply.github.com>
|
The E2E check is failing because this sample intentionally requires four user-provided values: an existing AKS resource group, cluster name, and two existing Entra group object IDs. The walkthrough documents these prerequisites, so there aren’t safe default values to provide. Should this prerequisite-based sample receive an E2E exception, or is there an approved method for supplying test prerequisites in this repository? |
…uickstart Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
|
Root cause and fix: Root cause: The e2e-check job runs terraform apply -input=false -auto-approve on each changed quickstart with no variables. quickstart/101-aks-entra-k8s-rbac intentionally requires four caller-supplied values (resource_group_name, aks_cluster_name, appdev_group_object_id, opssre_group_object_id), so apply failed with Error: No value for required variable. Fix (using the repo's sanctioned pattern for prerequisite-based samples, as in 202-machine-learning-moderately-secure-existing-VNet): Added quickstart/101-aks-entra-k8s-rbac/prequisite/ which creates a resource group, an AKS cluster with Microsoft Entra integration and Kubernetes RBAC (azure_rbac_enabled = false), and the two Entra security groups, exporting them as outputs. Note on the review comment about the folder name: prequisite is intentional — it matches the existing folder name and the prequistePath variable used by 202-machine-learning-moderately-secure-existing-VNet, so renaming it here would break consistency with the established convention. |
Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
Vishwajeet Ranade (vranade-microsoft)
left a comment
There was a problem hiding this comment.
Approving copilot changes. No manual changes involved.
Co-authored-by: vranade-microsoft <269690592+vranade-microsoft@users.noreply.github.com>
Vishwajeet Ranade (vranade-microsoft)
left a comment
There was a problem hiding this comment.
Approving changes made by Copilot. No manual edits involved.
Summary
Adds a Terraform quickstart for using Microsoft Entra ID groups with Kubernetes role-based access control (Kubernetes RBAC) in Azure Kubernetes Service (AKS).
The sample demonstrates how to scope existing Microsoft Entra groups to separate Kubernetes namespaces by using AKS Cluster User role assignments, Kubernetes Roles, and RoleBindings.
Includes
devandsreKubernetes namespacesValidation
terraform fmtcompleted successfullyterraform init -backend=falsecompleted successfullyterraform validatecompleted successfully