Google Associate Cloud Engineer Question 6
Select 3Google Cloud PlatformYou are tasked with ensuring that all projects within your organization's Google Cloud environment adhere to a specific set of security policies. These policies should prevent the creation of external IP addresses for virtual machines. You need to apply these policies efficiently to ensure compliance across all projects. Which steps should you take to achieve this?
- A
A. Set an organization policy at the organization level to disallow external IPs.
- B
B. Apply the policy to each project manually using Cloud Console.
- C
C. Use the Resource Manager API to apply the policy at the folder level if folders are used.
- D
D. Apply the policy to each virtual machine instance individually.
- E
E. Set the policy at the organization level and override it at the project level where exceptions are needed.
Show answer and explanation
Correct answers: A, C, E
Explanation
To efficiently enforce security policies across all projects within an organization on Google Cloud, you should use organization policies to manage constraints like disallowing external IPs. Applying the policy at the organization level ensures it is automatically inherited by all projects and resources, reducing administrative overhead and ensuring consistency. Using folders to apply policies can also be beneficial if your organization uses them for project grouping. Handling exceptions at the project level ensures flexibility without compromising overall security compliance.
- A. Correct.
A. Setting an organization policy at the organization level ensures that the policy is inherited by all resources within the organization, enforcing the rule globally.
- B. Incorrect.
B. Applying the policy manually to each project is inefficient and prone to errors, especially if there are numerous projects.
- C. Correct.
C. Using the Resource Manager API to apply the policy at the folder level is effective when the organization uses folders to group projects logically, ensuring consistent policy application.
- D. Incorrect.
D. Applying the policy to each virtual machine instance is not efficient and does not leverage Google Cloud's hierarchical policy enforcement capabilities.
- E. Correct.
E. Setting the policy at the organization level ensures broad coverage, and overriding it at the project level allows for flexibility where specific exceptions are necessary.