Class: Google::Apis::OsconfigV1alpha::OsPolicyAssignmentInstanceFilter
- Inherits:
-
Object
- Object
- Google::Apis::OsconfigV1alpha::OsPolicyAssignmentInstanceFilter
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/osconfig_v1alpha/classes.rb,
lib/google/apis/osconfig_v1alpha/representations.rb,
lib/google/apis/osconfig_v1alpha/representations.rb
Overview
Filters to select target VMs for an assignment. If more than one filter criteria is specified below, a VM will be selected if and only if it satisfies all of them.
Instance Attribute Summary collapse
-
#all ⇒ Boolean
(also: #all?)
Target all VMs in the project.
-
#exclusion_labels ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentLabelSet>
List of label sets used for VM exclusion.
-
#inclusion_labels ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentLabelSet>
List of label sets used for VM inclusion.
-
#inventories ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentInstanceFilterInventory>
List of inventories to select VMs.
-
#os_short_names ⇒ Array<String>
Deprecated.
Instance Method Summary collapse
-
#initialize(**args) ⇒ OsPolicyAssignmentInstanceFilter
constructor
A new instance of OsPolicyAssignmentInstanceFilter.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ OsPolicyAssignmentInstanceFilter
Returns a new instance of OsPolicyAssignmentInstanceFilter.
1195 1196 1197 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1195 def initialize(**args) update!(**args) end |
Instance Attribute Details
#all ⇒ Boolean Also known as: all?
Target all VMs in the project. If true, no other criteria is permitted.
Corresponds to the JSON property all
1167 1168 1169 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1167 def all @all end |
#exclusion_labels ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentLabelSet>
List of label sets used for VM exclusion. If the list has more than one label
set, the VM is excluded if any of the label sets are applicable for the VM.
Corresponds to the JSON property exclusionLabels
1174 1175 1176 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1174 def exclusion_labels @exclusion_labels end |
#inclusion_labels ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentLabelSet>
List of label sets used for VM inclusion. If the list has more than one
LabelSet, the VM is included if any of the label sets are applicable for the
VM.
Corresponds to the JSON property inclusionLabels
1181 1182 1183 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1181 def inclusion_labels @inclusion_labels end |
#inventories ⇒ Array<Google::Apis::OsconfigV1alpha::OsPolicyAssignmentInstanceFilterInventory>
List of inventories to select VMs. A VM is selected if its inventory data
matches at least one of the following inventories.
Corresponds to the JSON property inventories
1187 1188 1189 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1187 def inventories @inventories end |
#os_short_names ⇒ Array<String>
Deprecated. Use the inventories field instead. A VM is selected if it's OS
short name matches with any of the values provided in this list.
Corresponds to the JSON property osShortNames
1193 1194 1195 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1193 def os_short_names @os_short_names end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1200 1201 1202 1203 1204 1205 1206 |
# File 'lib/google/apis/osconfig_v1alpha/classes.rb', line 1200 def update!(**args) @all = args[:all] if args.key?(:all) @exclusion_labels = args[:exclusion_labels] if args.key?(:exclusion_labels) @inclusion_labels = args[:inclusion_labels] if args.key?(:inclusion_labels) @inventories = args[:inventories] if args.key?(:inventories) @os_short_names = args[:os_short_names] if args.key?(:os_short_names) end |