Class: Google::Apis::OsconfigV2::GoogleCloudOsconfigV2PolicyOrchestrator
- Inherits:
-
Object
- Object
- Google::Apis::OsconfigV2::GoogleCloudOsconfigV2PolicyOrchestrator
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/osconfig_v2/classes.rb,
lib/google/apis/osconfig_v2/representations.rb,
lib/google/apis/osconfig_v2/representations.rb
Overview
A policy orchestrator manages project-level and zone-level policy resources,
such as OS policy assignments. It provides methods to create, update, and
delete these resources across projects and locations at scale. The policy
orchestrator operates as a continuous loop. In each iteration, the
orchestrator identifies the set of resources to be modified and progressively
applies changes. If the set of resources changes over time (for example, if
you add new projects), subsequent iterations address those changes. The
orchestrator can either upsert or delete policy resources. For more details,
see the action and orchestrated_resource fields. The policy orchestrator
does not manage the lifecycle of the resources it creates. Each iteration is
independent and, besides Cloud Logging, the orchestrator retains only a
minimal history of past actions. Deleting the orchestrator does not affect
previously created resources; these resources remain in their current state.
Similarly, removing projects from the orchestrator's scope does not affect
existing resources.
Instance Attribute Summary collapse
-
#action ⇒ String
Required.
-
#create_time ⇒ String
Output only.
-
#description ⇒ String
Optional.
-
#etag ⇒ String
Output only.
-
#labels ⇒ Hash<String,String>
Optional.
-
#name ⇒ String
Immutable.
-
#orchestrated_resource ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2OrchestratedResource
Represents a resource that is being orchestrated by the policy orchestrator.
-
#orchestration_scope ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2OrchestrationScope
Defines a set of selectors which drive which resources are in scope of policy orchestration.
-
#orchestration_state ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2PolicyOrchestratorOrchestrationState
Describes the state of the orchestration process.
-
#reconciling ⇒ Boolean
(also: #reconciling?)
Output only.
-
#state ⇒ String
Optional.
-
#update_time ⇒ String
Output only.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GoogleCloudOsconfigV2PolicyOrchestrator
constructor
A new instance of GoogleCloudOsconfigV2PolicyOrchestrator.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ GoogleCloudOsconfigV2PolicyOrchestrator
Returns a new instance of GoogleCloudOsconfigV2PolicyOrchestrator.
535 536 537 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 535 def initialize(**args) update!(**args) end |
Instance Attribute Details
#action ⇒ String
Required. Action to be done by the orchestrator in projects/project_id/
zones/zone_id`locations defined by theorchestration_scope. Allowed
values: -UPSERT- Orchestrator will create or update target resources. -
DELETE- Orchestrator will delete target resources, if they exist
Corresponds to the JSON propertyaction`
465 466 467 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 465 def action @action end |
#create_time ⇒ String
Output only. Timestamp when the policy orchestrator resource was created.
Corresponds to the JSON property createTime
470 471 472 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 470 def create_time @create_time end |
#description ⇒ String
Optional. Freeform text describing the purpose of the resource.
Corresponds to the JSON property description
475 476 477 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 475 def description @description end |
#etag ⇒ String
Output only. This checksum is computed by the server based on the value of
other fields, and may be sent on update and delete requests to ensure the
client has an up-to-date value before proceeding.
Corresponds to the JSON property etag
482 483 484 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 482 def etag @etag end |
#labels ⇒ Hash<String,String>
Optional. Labels as key value pairs
Corresponds to the JSON property labels
487 488 489 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 487 def labels @labels end |
#name ⇒ String
Immutable. Identifier. In the following format: * organizations/
organization_id/locations/global/policyOrchestrators/orchestrator_id* `
folders/`folder_id`/locations/global/policyOrchestrators/`orchestrator_id *
projects/project_id_or_number/locations/global/policyOrchestrators/
orchestrator_id`
Corresponds to the JSON propertyname`
496 497 498 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 496 def name @name end |
#orchestrated_resource ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2OrchestratedResource
Represents a resource that is being orchestrated by the policy orchestrator.
Corresponds to the JSON property orchestratedResource
501 502 503 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 501 def orchestrated_resource @orchestrated_resource end |
#orchestration_scope ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2OrchestrationScope
Defines a set of selectors which drive which resources are in scope of policy
orchestration.
Corresponds to the JSON property orchestrationScope
507 508 509 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 507 def orchestration_scope @orchestration_scope end |
#orchestration_state ⇒ Google::Apis::OsconfigV2::GoogleCloudOsconfigV2PolicyOrchestratorOrchestrationState
Describes the state of the orchestration process.
Corresponds to the JSON property orchestrationState
512 513 514 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 512 def orchestration_state @orchestration_state end |
#reconciling ⇒ Boolean Also known as: reconciling?
Output only. Set to true, if there are ongoing changes being applied by the
orchestrator.
Corresponds to the JSON property reconciling
518 519 520 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 518 def reconciling @reconciling end |
#state ⇒ String
Optional. State of the orchestrator. Can be updated to change orchestrator
behaviour. Allowed values: - ACTIVE - orchestrator is actively looking for
actions to be taken. - STOPPED - orchestrator won't make any changes. Note:
There might be more states added in the future. We use string here instead of
an enum, to avoid the need of propagating new states to all the client code.
Corresponds to the JSON property state
528 529 530 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 528 def state @state end |
#update_time ⇒ String
Output only. Timestamp when the policy orchestrator resource was last modified.
Corresponds to the JSON property updateTime
533 534 535 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 533 def update_time @update_time end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
540 541 542 543 544 545 546 547 548 549 550 551 552 553 |
# File 'lib/google/apis/osconfig_v2/classes.rb', line 540 def update!(**args) @action = args[:action] if args.key?(:action) @create_time = args[:create_time] if args.key?(:create_time) @description = args[:description] if args.key?(:description) @etag = args[:etag] if args.key?(:etag) @labels = args[:labels] if args.key?(:labels) @name = args[:name] if args.key?(:name) @orchestrated_resource = args[:orchestrated_resource] if args.key?(:orchestrated_resource) @orchestration_scope = args[:orchestration_scope] if args.key?(:orchestration_scope) @orchestration_state = args[:orchestration_state] if args.key?(:orchestration_state) @reconciling = args[:reconciling] if args.key?(:reconciling) @state = args[:state] if args.key?(:state) @update_time = args[:update_time] if args.key?(:update_time) end |