How to restrict resource location to europe-west3?
Short answer
A Set the constraints/gcp.resourceLocations organization policy constraint to in:europe-west3-locations.
Question
Key Takeaways
This tests knowledge of Organization Policy constraints for location governance, specifically distinguishing between specific regions like europe-west3 and broader multi-regions like eu.
To restrict resource locations in Google Cloud, use the constraints/gcp.resourceLocations organization policy. The community confirms that setting this constraint to in:europe-west3-locations is the correct method to enforce regional limits.
Common mistake: Selecting Option C (in:eu-locations) is a common error because it restricts resources to all of Europe rather than specifically to the europe-west3 region.
Expert Analysis
Why the Answer Is Correct
Option A is correct because the constraints/gcp.resourceLocations Organization Policy is the Google-recommended method to enforce where resources can be created. Setting the value to in:europe-west3-locations ensures strict compliance by preventing resource creation in any other region.
Why the Other Options Are Wrong
Option B is incorrect because Terraform validations are client-side and can be bypassed by deploying via the Console or API. Option C is incorrect because in:eu-locations permits resources in any European region, violating the requirement for europe-west3 only. Option D is incorrect because reactive remediation (destroying resources) is inefficient and risky compared to preventive policy enforcement.
Community Comment Notes
Community comments overwhelmingly support Option A, citing the official Google Cloud documentation on defining location types. Commenters emphasize that this specific constraint syntax is the standard way to implement data residency and governance controls.
Official Reference
https://cloud.google.com/resource-manager/docs/organization-policy/defining-locations
This link opens the official vendor documentation in a new tab.
Exam Strategy
For governance questions involving resource restrictions, prioritize Organization Policies over Infrastructure as Code (IaC) logic or reactive scripts. Pay close attention to whether the question requires a specific region or a broader multi-region to avoid selecting overly permissive options.
Community Votes
100% of anonymous learners picked answer A. Votes are pick records left by other test-takers — they are not the verified answer.
Discussion 5 contributions
Compiled from public community threads and reader submissions, lightly edited for clarity. Handles and vote tallies are shown as recorded, and comments reflect the views of individual contributors.
From public community threads 5
-
raaad 👍 11 Answered A- The constraints/gcp.resourceLocations organization policy constraint is used to define where resources in the organization can be created. - Setting it to in:europe-west3-locations would specify that resources can only be created in the europe-west3 region.
-
scaenruy 👍 2 Answered ASet the constraints/gcp.resourceLocations organization policy constraint to in:europe-west3-locations.
-
b3e59c2 👍 2 Answered Ahttps://cloud.google.com/resource-manager/docs/organization-policy/defining-locations#location_types
-
chrissamharris 👍 1B, D B - Increase the Cloud Composer 2 environment size from medium to large. Increasing the environment size will provide more resources (including memory) to the entire environment, which should help mitigate memory usage issues. This will also support scaling if the jobs demand more resources. D. Increase the memory available to the Airflow workers. Increasing memory for Airflow workers will directly address the memory usage issue that's causing the pod evictions. By allocating more memory to the workers, they can handle larger tasks or more intensive workloads without failing due to memory constraints.
-
JyoGCP 👍 1 Answered AOption A
Reader comments & corrections
No reader corrections yet — spotted an error or have a note? Share it below.