A company is configuring access for a site reliability engineer (SRE) who needs to create, modify, and delete Google Kubernetes Engine (GKE) clusters and node pools in a single Google Cloud project named `k8s-platform-prod`. The engineer must not be able to modify project IAM policies, alter billing account settings, or manage unrelated services like Cloud Storage or BigQuery. Following Google Cloud recommended security practices and the principle of least privilege, which IAM configuration should you implement?
- Grant the Kubernetes Engine Admin (`roles/container.admin`) role to the engineer on the `k8s-platform-prod` project.Answer
- BGrant the Kubernetes Engine Admin (`roles/container.admin`) role to the engineer on the parent Folder containing `k8s-platform-prod`.
- CGrant the primitive Editor (`roles/editor`) role to the engineer on the `k8s-platform-prod` project.
- DGrant the primitive Owner (`roles/owner`) role to the engineer on the `k8s-platform-prod` project.
Answer
Grant the predefined role Kubernetes Engine Admin (`roles/container.admin`) to the user at the specific project level (`k8s-platform-prod`).
Granting the predefined Kubernetes Engine Admin role (`roles/container.admin`) at the project level provides all necessary permissions to manage GKE clusters and node pool resources within `k8s-platform-prod` while ensuring the user cannot alter project IAM policies, modify billing account configurations, or manage non-container resources.
Step-by-Step Solution
Key Concept
Principle of Least Privilege using Predefined IAM Roles at Project Scope