Manage project+zone level policies with google_os_config_v2_policy_orchestrator
mainThe google_os_config_v2_policy_orchestrator resource is used to manage OS Config v2 policy resources (such as OS Policy Assignments) at scale across multiple projects and locations. It provides a mechanism to create, update, and delete these resources by defining an orchestrated resource payload.
resource "google_os_config_v2_policy_orchestrator" "policy_orchestrator" {
policy_orchestrator_id = "po"
state = "ACTIVE"
action = "UPSERT"
orchestrated_resource {
id = "test-orchestrated-resource"
os_policy_assignment_v1_payload {
os_policies {
id = "test-os-policy"
mode = "VALIDATION"
resource_groups {
resources {
id = "resource-tf"
file {
content = "file-content-tf"
path = "file-path-tf-1"
state = "PRESENT"
}
}
}
}
instance_filter {
inventories {
os_short_name = "windows-10"
}
}
rollout {
disruption_budget {
percent = 100
}
min_wait_duration = "60s"
}
}
}
labels = {
state = "active"
}
}