Bird
0
0

You want to give a team member access to only start and stop virtual machines but not delete or create them. Which IAM approach is best?

hard📝 Best Practice Q15 of 15
GCP - Cloud IAM Advanced
You want to give a team member access to only start and stop virtual machines but not delete or create them. Which IAM approach is best?
ACreate a custom role with only 'start' and 'stop' permissions
BGive the 'roles/editor' role for full editing rights
CAssign the 'roles/viewer' role and let them request changes
DAssign the predefined 'roles/compute.instanceAdmin' role
Step-by-Step Solution
Solution:
  1. Step 1: Understand predefined roles limits

    'roles/compute.instanceAdmin' and 'roles/editor' provide broad permissions including create and delete, which is too much.
  2. Step 2: Use custom role for precise permissions

    Creating a custom role with only 'start' and 'stop' VM permissions limits access exactly as needed.
  3. Final Answer:

    Create a custom role with only 'start' and 'stop' permissions -> Option A
  4. Quick Check:

    Custom role = precise access control [OK]
Quick Trick: Use custom roles for exact permission needs [OK]
Common Mistakes:
  • Using broad predefined roles without restriction
  • Assuming viewer role allows start/stop
  • Giving editor role grants too many rights

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More GCP Quizzes