Update examples and tests
This commit is contained in:
committed by
Julio Castillo
parent
e4a1218d46
commit
3fc7144c4f
@@ -139,9 +139,19 @@ module "folder" {
|
||||
"compute.vmExternalIpAccess" = {
|
||||
rules = [{ deny = { all = true } }]
|
||||
}
|
||||
"essentialcontacts.managed.allowedContactDomains" = {
|
||||
rules = [
|
||||
{
|
||||
enforce = true
|
||||
parameters = jsonencode({
|
||||
allowedDomains = ["@example.com"]
|
||||
})
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
# tftest modules=1 resources=8 inventory=org-policies.yaml e2e
|
||||
# tftest modules=1 resources=9 inventory=org-policies.yaml e2e
|
||||
```
|
||||
|
||||
### Organization Policy Factory
|
||||
|
||||
@@ -46,6 +46,9 @@
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -70,4 +73,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -517,9 +517,19 @@ module "project" {
|
||||
"compute.vmExternalIpAccess" = {
|
||||
rules = [{ deny = { all = true } }]
|
||||
}
|
||||
"essentialcontacts.managed.allowedContactDomains" = {
|
||||
rules = [
|
||||
{
|
||||
enforce = true
|
||||
parameters = jsonencode({
|
||||
allowedDomains = ["@example.com"]
|
||||
})
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
# tftest modules=1 resources=8 inventory=org-policies.yaml e2e
|
||||
# tftest modules=1 resources=9 inventory=org-policies.yaml e2e
|
||||
```
|
||||
|
||||
### Organization Policy Factory
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2023 Google LLC
|
||||
# Copyright 2025 Google LLC
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -105,4 +105,4 @@ values:
|
||||
|
||||
counts:
|
||||
google_folder: 1
|
||||
google_org_policy_policy: 7
|
||||
google_org_policy_policy: 8
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright 2023 Google LLC
|
||||
# Copyright 2025 Google LLC
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
@@ -121,5 +121,5 @@ values:
|
||||
project_id: test-project
|
||||
|
||||
counts:
|
||||
google_org_policy_policy: 7
|
||||
google_org_policy_policy: 8
|
||||
google_project: 1
|
||||
|
||||
Reference in New Issue
Block a user