File tree 1 file changed +27
-0
lines changed
mmv1/third_party/terraform/services/orgpolicy
1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -459,3 +459,30 @@ func testAccCheckOrgPolicyPolicyDestroyProducer(t *testing.T) func(s *terraform.
459
459
}
460
460
}
461
461
462
+ func testAccOrgPolicyPolicy_EnforceParameterizedMCPolicy (context map [string ]interface {}) string {
463
+ return acctest .Nprintf (`
464
+ resource "google_org_policy_policy" "primary" {
465
+ name = "projects/${google_project.basic.name}/policies/constraints/compute.managed.restrictDiskCreation"
466
+ parent = "projects/${google_project.basic.name}"
467
+
468
+ spec {
469
+ rules {
470
+ enforce = "TRUE"
471
+ parameters {
472
+ "isSizeLimitCheck" : True,
473
+ "allowedDiskTypes" : ["pd-ssd"]
474
+ }
475
+ }
476
+ }
477
+ }
478
+
479
+ resource "google_project" "basic" {
480
+ project_id = "tf-test-id%{random_suffix}"
481
+ name = "tf-test-id%{random_suffix}"
482
+ org_id = "%{org_id}"
483
+ deletion_policy = "DELETE"
484
+ }
485
+
486
+
487
+ ` , context )
488
+ }
You can’t perform that action at this time.
0 commit comments