Class: Google::Apis::ClouddeployV1::DeployPolicyResourceSelector

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/clouddeploy_v1/classes.rb,
lib/google/apis/clouddeploy_v1/representations.rb,
lib/google/apis/clouddeploy_v1/representations.rb

Overview

Contains information on the resources to select for a deploy policy. Attributes provided must all match the resource in order for policy restrictions to apply. For example, if delivery pipelines attributes given are an id "prod" and labels "foo: bar", a delivery pipeline resource must match both that id and have that label in order to be subject to the policy.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ DeployPolicyResourceSelector

Returns a new instance of DeployPolicyResourceSelector.



2192
2193
2194
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 2192

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#delivery_pipelineGoogle::Apis::ClouddeployV1::DeliveryPipelineAttribute

Contains criteria for selecting DeliveryPipelines. Corresponds to the JSON property deliveryPipeline



2184
2185
2186
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 2184

def delivery_pipeline
  @delivery_pipeline
end

#targetGoogle::Apis::ClouddeployV1::TargetAttribute

Contains criteria for selecting Targets. This could be used to select targets for a Deploy Policy or for an Automation. Corresponds to the JSON property target



2190
2191
2192
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 2190

def target
  @target
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2197
2198
2199
2200
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 2197

def update!(**args)
  @delivery_pipeline = args[:delivery_pipeline] if args.key?(:delivery_pipeline)
  @target = args[:target] if args.key?(:target)
end