google-cloud-os_config-v1 0.5.0 → 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. checksums.yaml +4 -4
  2. data/lib/google/cloud/os_config/v1/os_config_service/client.rb +198 -27
  3. data/lib/google/cloud/os_config/v1/os_config_zonal_service/client.rb +1628 -0
  4. data/lib/google/cloud/os_config/v1/os_config_zonal_service/credentials.rb +51 -0
  5. data/lib/google/cloud/os_config/v1/os_config_zonal_service/operations.rb +767 -0
  6. data/lib/google/cloud/os_config/v1/os_config_zonal_service/paths.rb +192 -0
  7. data/lib/google/cloud/os_config/v1/os_config_zonal_service.rb +53 -0
  8. data/lib/google/cloud/os_config/v1/version.rb +1 -1
  9. data/lib/google/cloud/os_config/v1.rb +1 -0
  10. data/lib/google/cloud/osconfig/v1/inventory_pb.rb +37 -9
  11. data/lib/google/cloud/osconfig/v1/os_policy_assignment_reports_pb.rb +92 -0
  12. data/lib/google/cloud/osconfig/v1/os_policy_assignments_pb.rb +134 -0
  13. data/lib/google/cloud/osconfig/v1/os_policy_pb.rb +204 -0
  14. data/lib/google/cloud/osconfig/v1/osconfig_service_pb.rb +2 -2
  15. data/lib/google/cloud/osconfig/v1/osconfig_service_services_pb.rb +1 -1
  16. data/lib/google/cloud/osconfig/v1/osconfig_zonal_service_pb.rb +25 -0
  17. data/lib/google/cloud/osconfig/v1/osconfig_zonal_service_services_pb.rb +107 -0
  18. data/lib/google/cloud/osconfig/v1/patch_deployments_pb.rb +3 -2
  19. data/lib/google/cloud/osconfig/v1/patch_jobs_pb.rb +2 -2
  20. data/lib/google/cloud/osconfig/v1/vulnerability_pb.rb +127 -0
  21. data/proto_docs/google/cloud/osconfig/v1/inventory.rb +111 -20
  22. data/proto_docs/google/cloud/osconfig/v1/os_policy.rb +597 -0
  23. data/proto_docs/google/cloud/osconfig/v1/os_policy_assignment_reports.rb +293 -0
  24. data/proto_docs/google/cloud/osconfig/v1/os_policy_assignments.rb +392 -0
  25. data/proto_docs/google/cloud/osconfig/v1/patch_deployments.rb +4 -0
  26. data/proto_docs/google/cloud/osconfig/v1/vulnerability.rb +374 -0
  27. data/proto_docs/google/longrunning/operations.rb +164 -0
  28. data/proto_docs/google/protobuf/any.rb +141 -0
  29. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  30. data/proto_docs/google/rpc/status.rb +46 -0
  31. metadata +21 -2
@@ -0,0 +1,293 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module OsConfig
23
+ module V1
24
+ # Get a report of the OS policy assignment for a VM instance.
25
+ # @!attribute [rw] name
26
+ # @return [::String]
27
+ # Required. API resource name for OS policy assignment report.
28
+ #
29
+ # Format:
30
+ # `/projects/{project}/locations/{location}/instances/{instance}/osPolicyAssignments/{assignment}/report`
31
+ #
32
+ # For `{project}`, either `project-number` or `project-id` can be provided.
33
+ # For `{instance_id}`, either Compute Engine `instance-id` or `instance-name`
34
+ # can be provided.
35
+ # For `{assignment_id}`, the OSPolicyAssignment id must be provided.
36
+ class GetOSPolicyAssignmentReportRequest
37
+ include ::Google::Protobuf::MessageExts
38
+ extend ::Google::Protobuf::MessageExts::ClassMethods
39
+ end
40
+
41
+ # List the OS policy assignment reports for VM instances.
42
+ # @!attribute [rw] parent
43
+ # @return [::String]
44
+ # Required. The parent resource name.
45
+ #
46
+ # Format:
47
+ # `projects/{project}/locations/{location}/instances/{instance}/osPolicyAssignments/{assignment}/reports`
48
+ #
49
+ # For `{project}`, either `project-number` or `project-id` can be provided.
50
+ # For `{instance}`, either `instance-name`, `instance-id`, or `-` can be
51
+ # provided. If '-' is provided, the response will include
52
+ # OSPolicyAssignmentReports for all instances in the project/location.
53
+ # For `{assignment}`, either `assignment-id` or `-` can be provided. If '-'
54
+ # is provided, the response will include OSPolicyAssignmentReports for all
55
+ # OSPolicyAssignments in the project/location.
56
+ # Either \\{instance} or \\{assignment} must be `-`.
57
+ #
58
+ # For example:
59
+ # `projects/{project}/locations/{location}/instances/{instance}/osPolicyAssignments/-/reports`
60
+ # returns all reports for the instance
61
+ # `projects/{project}/locations/{location}/instances/-/osPolicyAssignments/{assignment-id}/reports`
62
+ # returns all the reports for the given assignment across all instances.
63
+ # `projects/{project}/locations/{location}/instances/-/osPolicyAssignments/-/reports`
64
+ # returns all the reports for all assignments across all instances.
65
+ # @!attribute [rw] page_size
66
+ # @return [::Integer]
67
+ # The maximum number of results to return.
68
+ # @!attribute [rw] filter
69
+ # @return [::String]
70
+ # If provided, this field specifies the criteria that must be met by the
71
+ # `OSPolicyAssignmentReport` API resource that is included in the response.
72
+ # @!attribute [rw] page_token
73
+ # @return [::String]
74
+ # A pagination token returned from a previous call to the
75
+ # `ListOSPolicyAssignmentReports` method that indicates where this listing
76
+ # should continue from.
77
+ class ListOSPolicyAssignmentReportsRequest
78
+ include ::Google::Protobuf::MessageExts
79
+ extend ::Google::Protobuf::MessageExts::ClassMethods
80
+ end
81
+
82
+ # A response message for listing OS Policy assignment reports including the
83
+ # page of results and page token.
84
+ # @!attribute [rw] os_policy_assignment_reports
85
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport>]
86
+ # List of OS policy assignment reports.
87
+ # @!attribute [rw] next_page_token
88
+ # @return [::String]
89
+ # The pagination token to retrieve the next page of OS policy assignment
90
+ # report objects.
91
+ class ListOSPolicyAssignmentReportsResponse
92
+ include ::Google::Protobuf::MessageExts
93
+ extend ::Google::Protobuf::MessageExts::ClassMethods
94
+ end
95
+
96
+ # A report of the OS policy assignment status for a given instance.
97
+ # @!attribute [rw] name
98
+ # @return [::String]
99
+ # The `OSPolicyAssignmentReport` API resource name.
100
+ #
101
+ # Format:
102
+ # `projects/{project_number}/locations/{location}/instances/{instance_id}/osPolicyAssignments/{os_policy_assignment_id}/report`
103
+ # @!attribute [rw] instance
104
+ # @return [::String]
105
+ # The Compute Engine VM instance name.
106
+ # @!attribute [rw] os_policy_assignment
107
+ # @return [::String]
108
+ # Reference to the `OSPolicyAssignment` API resource that the `OSPolicy`
109
+ # belongs to.
110
+ #
111
+ # Format:
112
+ # `projects/{project_number}/locations/{location}/osPolicyAssignments/{os_policy_assignment_id@revision_id}`
113
+ # @!attribute [rw] os_policy_compliances
114
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance>]
115
+ # Compliance data for each `OSPolicy` that is applied to the VM.
116
+ # @!attribute [rw] update_time
117
+ # @return [::Google::Protobuf::Timestamp]
118
+ # Timestamp for when the report was last generated.
119
+ # @!attribute [rw] last_run_id
120
+ # @return [::String]
121
+ # Unique identifier of the last attempted run to apply the OS policies
122
+ # associated with this assignment on the VM.
123
+ #
124
+ # This ID is logged by the OS Config agent while applying the OS
125
+ # policies associated with this assignment on the VM.
126
+ # NOTE: If the service is unable to successfully connect to the agent for
127
+ # this run, then this id will not be available in the agent logs.
128
+ class OSPolicyAssignmentReport
129
+ include ::Google::Protobuf::MessageExts
130
+ extend ::Google::Protobuf::MessageExts::ClassMethods
131
+
132
+ # Compliance data for an OS policy
133
+ # @!attribute [rw] os_policy_id
134
+ # @return [::String]
135
+ # The OS policy id
136
+ # @!attribute [rw] compliance_state
137
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::ComplianceState]
138
+ # The compliance state of the OS policy.
139
+ # @!attribute [rw] compliance_state_reason
140
+ # @return [::String]
141
+ # The reason for the OS policy to be in an unknown compliance state.
142
+ # This field is always populated when `compliance_state` is `UNKNOWN`.
143
+ #
144
+ # If populated, the field can contain one of the following values:
145
+ #
146
+ # * `vm-not-running`: The VM was not running.
147
+ # * `os-policies-not-supported-by-agent`: The version of the OS Config
148
+ # agent running on the VM does not support running OS policies.
149
+ # * `no-agent-detected`: The OS Config agent is not detected for the VM.
150
+ # * `resource-execution-errors`: The OS Config agent encountered errors
151
+ # while executing one or more resources in the policy. See
152
+ # `os_policy_resource_compliances` for details.
153
+ # * `task-timeout`: The task sent to the agent to apply the policy timed
154
+ # out.
155
+ # * `unexpected-agent-state`: The OS Config agent did not report the final
156
+ # status of the task that attempted to apply the policy. Instead, the agent
157
+ # unexpectedly started working on a different task. This mostly happens
158
+ # when the agent or VM unexpectedly restarts while applying OS policies.
159
+ # * `internal-service-errors`: Internal service errors were encountered
160
+ # while attempting to apply the policy.
161
+ # @!attribute [rw] os_policy_resource_compliances
162
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::OSPolicyResourceCompliance>]
163
+ # Compliance data for each resource within the policy that is applied to
164
+ # the VM.
165
+ class OSPolicyCompliance
166
+ include ::Google::Protobuf::MessageExts
167
+ extend ::Google::Protobuf::MessageExts::ClassMethods
168
+
169
+ # Compliance data for an OS policy resource.
170
+ # @!attribute [rw] os_policy_resource_id
171
+ # @return [::String]
172
+ # The ID of the OS policy resource.
173
+ # @!attribute [rw] config_steps
174
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::OSPolicyResourceCompliance::OSPolicyResourceConfigStep>]
175
+ # Ordered list of configuration completed by the agent for the OS policy
176
+ # resource.
177
+ # @!attribute [rw] compliance_state
178
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::OSPolicyResourceCompliance::ComplianceState]
179
+ # The compliance state of the resource.
180
+ # @!attribute [rw] compliance_state_reason
181
+ # @return [::String]
182
+ # A reason for the resource to be in the given compliance state.
183
+ # This field is always populated when `compliance_state` is `UNKNOWN`.
184
+ #
185
+ # The following values are supported when `compliance_state == UNKNOWN`
186
+ #
187
+ # * `execution-errors`: Errors were encountered by the agent while
188
+ # executing the resource and the compliance state couldn't be
189
+ # determined.
190
+ # * `execution-skipped-by-agent`: Resource execution was skipped by the
191
+ # agent because errors were encountered while executing prior resources
192
+ # in the OS policy.
193
+ # * `os-policy-execution-attempt-failed`: The execution of the OS policy
194
+ # containing this resource failed and the compliance state couldn't be
195
+ # determined.
196
+ # @!attribute [rw] exec_resource_output
197
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::OSPolicyResourceCompliance::ExecResourceOutput]
198
+ # ExecResource specific output.
199
+ class OSPolicyResourceCompliance
200
+ include ::Google::Protobuf::MessageExts
201
+ extend ::Google::Protobuf::MessageExts::ClassMethods
202
+
203
+ # Step performed by the OS Config agent for configuring an
204
+ # `OSPolicy` resource to its desired state.
205
+ # @!attribute [rw] type
206
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentReport::OSPolicyCompliance::OSPolicyResourceCompliance::OSPolicyResourceConfigStep::Type]
207
+ # Configuration step type.
208
+ # @!attribute [rw] error_message
209
+ # @return [::String]
210
+ # An error message recorded during the execution of this step.
211
+ # Only populated if errors were encountered during this step execution.
212
+ class OSPolicyResourceConfigStep
213
+ include ::Google::Protobuf::MessageExts
214
+ extend ::Google::Protobuf::MessageExts::ClassMethods
215
+
216
+ # Supported configuration step types
217
+ module Type
218
+ # Default value. This value is unused.
219
+ TYPE_UNSPECIFIED = 0
220
+
221
+ # Checks for resource conflicts such as schema errors.
222
+ VALIDATION = 1
223
+
224
+ # Checks the current status of the desired state for a resource.
225
+ DESIRED_STATE_CHECK = 2
226
+
227
+ # Enforces the desired state for a resource that is not in desired
228
+ # state.
229
+ DESIRED_STATE_ENFORCEMENT = 3
230
+
231
+ # Re-checks the status of the desired state. This check is done
232
+ # for a resource after the enforcement of all OS policies.
233
+ #
234
+ # This step is used to determine the final desired state status for
235
+ # the resource. It accounts for any resources that might have drifted
236
+ # from their desired state due to side effects from executing other
237
+ # resources.
238
+ DESIRED_STATE_CHECK_POST_ENFORCEMENT = 4
239
+ end
240
+ end
241
+
242
+ # ExecResource specific output.
243
+ # @!attribute [rw] enforcement_output
244
+ # @return [::String]
245
+ # Output from enforcement phase output file (if run).
246
+ # Output size is limited to 100K bytes.
247
+ class ExecResourceOutput
248
+ include ::Google::Protobuf::MessageExts
249
+ extend ::Google::Protobuf::MessageExts::ClassMethods
250
+ end
251
+
252
+ # Possible compliance states for a resource.
253
+ module ComplianceState
254
+ # The resource is in an unknown compliance state.
255
+ #
256
+ # To get more details about why the policy is in this state, review
257
+ # the output of the `compliance_state_reason` field.
258
+ UNKNOWN = 0
259
+
260
+ # Resource is compliant.
261
+ COMPLIANT = 1
262
+
263
+ # Resource is non-compliant.
264
+ NON_COMPLIANT = 2
265
+ end
266
+ end
267
+
268
+ # Possible compliance states for an os policy.
269
+ module ComplianceState
270
+ # The policy is in an unknown compliance state.
271
+ #
272
+ # Refer to the field `compliance_state_reason` to learn the exact reason
273
+ # for the policy to be in this compliance state.
274
+ UNKNOWN = 0
275
+
276
+ # Policy is compliant.
277
+ #
278
+ # The policy is compliant if all the underlying resources are also
279
+ # compliant.
280
+ COMPLIANT = 1
281
+
282
+ # Policy is non-compliant.
283
+ #
284
+ # The policy is non-compliant if one or more underlying resources are
285
+ # non-compliant.
286
+ NON_COMPLIANT = 2
287
+ end
288
+ end
289
+ end
290
+ end
291
+ end
292
+ end
293
+ end
@@ -0,0 +1,392 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2021 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module OsConfig
23
+ module V1
24
+ # OS policy assignment is an API resource that is used to
25
+ # apply a set of OS policies to a dynamically targeted group of Compute Engine
26
+ # VM instances.
27
+ #
28
+ # An OS policy is used to define the desired state configuration for a
29
+ # Compute Engine VM instance through a set of configuration resources that
30
+ # provide capabilities such as installing or removing software packages, or
31
+ # executing a script.
32
+ #
33
+ # For more information, see [OS policy and OS policy
34
+ # assignment](https://cloud.google.com/compute/docs/os-configuration-management/working-with-os-policies).
35
+ # @!attribute [rw] name
36
+ # @return [::String]
37
+ # Resource name.
38
+ #
39
+ # Format:
40
+ # `projects/{project_number}/locations/{location}/osPolicyAssignments/{os_policy_assignment_id}`
41
+ #
42
+ # This field is ignored when you create an OS policy assignment.
43
+ # @!attribute [rw] description
44
+ # @return [::String]
45
+ # OS policy assignment description.
46
+ # Length of the description is limited to 1024 characters.
47
+ # @!attribute [rw] os_policies
48
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicy>]
49
+ # Required. List of OS policies to be applied to the VMs.
50
+ # @!attribute [rw] instance_filter
51
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignment::InstanceFilter]
52
+ # Required. Filter to select VMs.
53
+ # @!attribute [rw] rollout
54
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignment::Rollout]
55
+ # Required. Rollout to deploy the OS policy assignment.
56
+ # A rollout is triggered in the following situations:
57
+ # 1) OSPolicyAssignment is created.
58
+ # 2) OSPolicyAssignment is updated and the update contains changes to one of
59
+ # the following fields:
60
+ # - instance_filter
61
+ # - os_policies
62
+ # 3) OSPolicyAssignment is deleted.
63
+ # @!attribute [r] revision_id
64
+ # @return [::String]
65
+ # Output only. The assignment revision ID
66
+ # A new revision is committed whenever a rollout is triggered for a OS policy
67
+ # assignment
68
+ # @!attribute [r] revision_create_time
69
+ # @return [::Google::Protobuf::Timestamp]
70
+ # Output only. The timestamp that the revision was created.
71
+ # @!attribute [rw] etag
72
+ # @return [::String]
73
+ # The etag for this OS policy assignment.
74
+ # If this is provided on update, it must match the server's etag.
75
+ # @!attribute [r] rollout_state
76
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignment::RolloutState]
77
+ # Output only. OS policy assignment rollout state
78
+ # @!attribute [r] baseline
79
+ # @return [::Boolean]
80
+ # Output only. Indicates that this revision has been successfully rolled out
81
+ # in this zone and new VMs will be assigned OS policies from this revision.
82
+ #
83
+ # For a given OS policy assignment, there is only one revision with a value
84
+ # of `true` for this field.
85
+ # @!attribute [r] deleted
86
+ # @return [::Boolean]
87
+ # Output only. Indicates that this revision deletes the OS policy assignment.
88
+ # @!attribute [r] reconciling
89
+ # @return [::Boolean]
90
+ # Output only. Indicates that reconciliation is in progress for the revision.
91
+ # This value is `true` when the `rollout_state` is one of:
92
+ # * IN_PROGRESS
93
+ # * CANCELLING
94
+ # @!attribute [r] uid
95
+ # @return [::String]
96
+ # Output only. Server generated unique id for the OS policy assignment
97
+ # resource.
98
+ class OSPolicyAssignment
99
+ include ::Google::Protobuf::MessageExts
100
+ extend ::Google::Protobuf::MessageExts::ClassMethods
101
+
102
+ # Message representing label set.
103
+ # * A label is a key value pair set for a VM.
104
+ # * A LabelSet is a set of labels.
105
+ # * Labels within a LabelSet are ANDed. In other words, a LabelSet is
106
+ # applicable for a VM only if it matches all the labels in the
107
+ # LabelSet.
108
+ # * Example: A LabelSet with 2 labels: `env=prod` and `type=webserver` will
109
+ # only be applicable for those VMs with both labels
110
+ # present.
111
+ # @!attribute [rw] labels
112
+ # @return [::Google::Protobuf::Map{::String => ::String}]
113
+ # Labels are identified by key/value pairs in this map.
114
+ # A VM should contain all the key/value pairs specified in this
115
+ # map to be selected.
116
+ class LabelSet
117
+ include ::Google::Protobuf::MessageExts
118
+ extend ::Google::Protobuf::MessageExts::ClassMethods
119
+
120
+ # @!attribute [rw] key
121
+ # @return [::String]
122
+ # @!attribute [rw] value
123
+ # @return [::String]
124
+ class LabelsEntry
125
+ include ::Google::Protobuf::MessageExts
126
+ extend ::Google::Protobuf::MessageExts::ClassMethods
127
+ end
128
+ end
129
+
130
+ # Filters to select target VMs for an assignment.
131
+ #
132
+ # If more than one filter criteria is specified below, a VM will be selected
133
+ # if and only if it satisfies all of them.
134
+ # @!attribute [rw] all
135
+ # @return [::Boolean]
136
+ # Target all VMs in the project. If true, no other criteria is
137
+ # permitted.
138
+ # @!attribute [rw] inclusion_labels
139
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignment::LabelSet>]
140
+ # List of label sets used for VM inclusion.
141
+ #
142
+ # If the list has more than one `LabelSet`, the VM is included if any
143
+ # of the label sets are applicable for the VM.
144
+ # @!attribute [rw] exclusion_labels
145
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignment::LabelSet>]
146
+ # List of label sets used for VM exclusion.
147
+ #
148
+ # If the list has more than one label set, the VM is excluded if any
149
+ # of the label sets are applicable for the VM.
150
+ # @!attribute [rw] inventories
151
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignment::InstanceFilter::Inventory>]
152
+ # List of inventories to select VMs.
153
+ #
154
+ # A VM is selected if its inventory data matches at least one of the
155
+ # following inventories.
156
+ class InstanceFilter
157
+ include ::Google::Protobuf::MessageExts
158
+ extend ::Google::Protobuf::MessageExts::ClassMethods
159
+
160
+ # VM inventory details.
161
+ # @!attribute [rw] os_short_name
162
+ # @return [::String]
163
+ # Required. The OS short name
164
+ # @!attribute [rw] os_version
165
+ # @return [::String]
166
+ # The OS version
167
+ #
168
+ # Prefix matches are supported if asterisk(*) is provided as the
169
+ # last character. For example, to match all versions with a major
170
+ # version of `7`, specify the following value for this field `7.*`
171
+ #
172
+ # An empty string matches all OS versions.
173
+ class Inventory
174
+ include ::Google::Protobuf::MessageExts
175
+ extend ::Google::Protobuf::MessageExts::ClassMethods
176
+ end
177
+ end
178
+
179
+ # Message to configure the rollout at the zonal level for the OS policy
180
+ # assignment.
181
+ # @!attribute [rw] disruption_budget
182
+ # @return [::Google::Cloud::OsConfig::V1::FixedOrPercent]
183
+ # Required. The maximum number (or percentage) of VMs per zone to disrupt
184
+ # at any given moment.
185
+ # @!attribute [rw] min_wait_duration
186
+ # @return [::Google::Protobuf::Duration]
187
+ # Required. This determines the minimum duration of time to wait after the
188
+ # configuration changes are applied through the current rollout. A
189
+ # VM continues to count towards the `disruption_budget` at least
190
+ # until this duration of time has passed after configuration changes are
191
+ # applied.
192
+ class Rollout
193
+ include ::Google::Protobuf::MessageExts
194
+ extend ::Google::Protobuf::MessageExts::ClassMethods
195
+ end
196
+
197
+ # OS policy assignment rollout state
198
+ module RolloutState
199
+ # Invalid value
200
+ ROLLOUT_STATE_UNSPECIFIED = 0
201
+
202
+ # The rollout is in progress.
203
+ IN_PROGRESS = 1
204
+
205
+ # The rollout is being cancelled.
206
+ CANCELLING = 2
207
+
208
+ # The rollout is cancelled.
209
+ CANCELLED = 3
210
+
211
+ # The rollout has completed successfully.
212
+ SUCCEEDED = 4
213
+ end
214
+ end
215
+
216
+ # OS policy assignment operation metadata provided by OS policy assignment API
217
+ # methods that return long running operations.
218
+ # @!attribute [rw] os_policy_assignment
219
+ # @return [::String]
220
+ # Reference to the `OSPolicyAssignment` API resource.
221
+ #
222
+ # Format:
223
+ # `projects/{project_number}/locations/{location}/osPolicyAssignments/{os_policy_assignment_id@revision_id}`
224
+ # @!attribute [rw] api_method
225
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentOperationMetadata::APIMethod]
226
+ # The OS policy assignment API method.
227
+ # @!attribute [rw] rollout_state
228
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignmentOperationMetadata::RolloutState]
229
+ # State of the rollout
230
+ # @!attribute [rw] rollout_start_time
231
+ # @return [::Google::Protobuf::Timestamp]
232
+ # Rollout start time
233
+ # @!attribute [rw] rollout_update_time
234
+ # @return [::Google::Protobuf::Timestamp]
235
+ # Rollout update time
236
+ class OSPolicyAssignmentOperationMetadata
237
+ include ::Google::Protobuf::MessageExts
238
+ extend ::Google::Protobuf::MessageExts::ClassMethods
239
+
240
+ # The OS policy assignment API method.
241
+ module APIMethod
242
+ # Invalid value
243
+ API_METHOD_UNSPECIFIED = 0
244
+
245
+ # Create OS policy assignment API method
246
+ CREATE = 1
247
+
248
+ # Update OS policy assignment API method
249
+ UPDATE = 2
250
+
251
+ # Delete OS policy assignment API method
252
+ DELETE = 3
253
+ end
254
+
255
+ # State of the rollout
256
+ module RolloutState
257
+ # Invalid value
258
+ ROLLOUT_STATE_UNSPECIFIED = 0
259
+
260
+ # The rollout is in progress.
261
+ IN_PROGRESS = 1
262
+
263
+ # The rollout is being cancelled.
264
+ CANCELLING = 2
265
+
266
+ # The rollout is cancelled.
267
+ CANCELLED = 3
268
+
269
+ # The rollout has completed successfully.
270
+ SUCCEEDED = 4
271
+ end
272
+ end
273
+
274
+ # A request message to create an OS policy assignment
275
+ # @!attribute [rw] parent
276
+ # @return [::String]
277
+ # Required. The parent resource name in the form:
278
+ # projects/\\{project}/locations/\\{location}
279
+ # @!attribute [rw] os_policy_assignment
280
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignment]
281
+ # Required. The OS policy assignment to be created.
282
+ # @!attribute [rw] os_policy_assignment_id
283
+ # @return [::String]
284
+ # Required. The logical name of the OS policy assignment in the project
285
+ # with the following restrictions:
286
+ #
287
+ # * Must contain only lowercase letters, numbers, and hyphens.
288
+ # * Must start with a letter.
289
+ # * Must be between 1-63 characters.
290
+ # * Must end with a number or a letter.
291
+ # * Must be unique within the project.
292
+ class CreateOSPolicyAssignmentRequest
293
+ include ::Google::Protobuf::MessageExts
294
+ extend ::Google::Protobuf::MessageExts::ClassMethods
295
+ end
296
+
297
+ # A request message to update an OS policy assignment
298
+ # @!attribute [rw] os_policy_assignment
299
+ # @return [::Google::Cloud::OsConfig::V1::OSPolicyAssignment]
300
+ # Required. The updated OS policy assignment.
301
+ # @!attribute [rw] update_mask
302
+ # @return [::Google::Protobuf::FieldMask]
303
+ # Optional. Field mask that controls which fields of the assignment should be
304
+ # updated.
305
+ class UpdateOSPolicyAssignmentRequest
306
+ include ::Google::Protobuf::MessageExts
307
+ extend ::Google::Protobuf::MessageExts::ClassMethods
308
+ end
309
+
310
+ # A request message to get an OS policy assignment
311
+ # @!attribute [rw] name
312
+ # @return [::String]
313
+ # Required. The resource name of OS policy assignment.
314
+ #
315
+ # Format:
316
+ # `projects/{project}/locations/{location}/osPolicyAssignments/{os_policy_assignment}@{revisionId}`
317
+ class GetOSPolicyAssignmentRequest
318
+ include ::Google::Protobuf::MessageExts
319
+ extend ::Google::Protobuf::MessageExts::ClassMethods
320
+ end
321
+
322
+ # A request message to list OS policy assignments for a parent resource
323
+ # @!attribute [rw] parent
324
+ # @return [::String]
325
+ # Required. The parent resource name.
326
+ # @!attribute [rw] page_size
327
+ # @return [::Integer]
328
+ # The maximum number of assignments to return.
329
+ # @!attribute [rw] page_token
330
+ # @return [::String]
331
+ # A pagination token returned from a previous call to
332
+ # `ListOSPolicyAssignments` that indicates where this listing should continue
333
+ # from.
334
+ class ListOSPolicyAssignmentsRequest
335
+ include ::Google::Protobuf::MessageExts
336
+ extend ::Google::Protobuf::MessageExts::ClassMethods
337
+ end
338
+
339
+ # A response message for listing all assignments under given parent.
340
+ # @!attribute [rw] os_policy_assignments
341
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignment>]
342
+ # The list of assignments
343
+ # @!attribute [rw] next_page_token
344
+ # @return [::String]
345
+ # The pagination token to retrieve the next page of OS policy assignments.
346
+ class ListOSPolicyAssignmentsResponse
347
+ include ::Google::Protobuf::MessageExts
348
+ extend ::Google::Protobuf::MessageExts::ClassMethods
349
+ end
350
+
351
+ # A request message to list revisions for a OS policy assignment
352
+ # @!attribute [rw] name
353
+ # @return [::String]
354
+ # Required. The name of the OS policy assignment to list revisions for.
355
+ # @!attribute [rw] page_size
356
+ # @return [::Integer]
357
+ # The maximum number of revisions to return.
358
+ # @!attribute [rw] page_token
359
+ # @return [::String]
360
+ # A pagination token returned from a previous call to
361
+ # `ListOSPolicyAssignmentRevisions` that indicates where this listing should
362
+ # continue from.
363
+ class ListOSPolicyAssignmentRevisionsRequest
364
+ include ::Google::Protobuf::MessageExts
365
+ extend ::Google::Protobuf::MessageExts::ClassMethods
366
+ end
367
+
368
+ # A response message for listing all revisions for a OS policy assignment.
369
+ # @!attribute [rw] os_policy_assignments
370
+ # @return [::Array<::Google::Cloud::OsConfig::V1::OSPolicyAssignment>]
371
+ # The OS policy assignment revisions
372
+ # @!attribute [rw] next_page_token
373
+ # @return [::String]
374
+ # The pagination token to retrieve the next page of OS policy assignment
375
+ # revisions.
376
+ class ListOSPolicyAssignmentRevisionsResponse
377
+ include ::Google::Protobuf::MessageExts
378
+ extend ::Google::Protobuf::MessageExts::ClassMethods
379
+ end
380
+
381
+ # A request message for deleting a OS policy assignment.
382
+ # @!attribute [rw] name
383
+ # @return [::String]
384
+ # Required. The name of the OS policy assignment to be deleted
385
+ class DeleteOSPolicyAssignmentRequest
386
+ include ::Google::Protobuf::MessageExts
387
+ extend ::Google::Protobuf::MessageExts::ClassMethods
388
+ end
389
+ end
390
+ end
391
+ end
392
+ end