Class: Google::Apis::ClouddeployV1::Automation

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

An Automation resource in the Cloud Deploy API. An Automation enables the automation of manually driven actions for a Delivery Pipeline, which includes Release promotion among Targets, Rollout repair and Rollout deployment strategy advancement. The intention of Automation is to reduce manual intervention in the continuous delivery process.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Automation

Returns a new instance of Automation.



436
437
438
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 436

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

Instance Attribute Details

#annotationsHash<String,String>

Optional. User annotations. These attributes can only be set and used by the user, and not by Cloud Deploy. Annotations must meet the following constraints:

  • Annotations are key/value pairs. * Valid annotation keys have two segments: an optional prefix and name, separated by a slash (/). * The name segment is required and must be 63 characters or less, beginning and ending with an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.), and alphanumerics between. * The prefix is optional. If specified, the prefix must be a DNS subdomain: a series of DNS labels separated by dots(. ), not longer than 253 characters in total, followed by a slash (/). See https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/# syntax-and-character-set for more details. Corresponds to the JSON property annotations

Returns:

  • (Hash<String,String>)


364
365
366
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 364

def annotations
  @annotations
end

#create_timeString

Output only. Time at which the automation was created. Corresponds to the JSON property createTime

Returns:

  • (String)


369
370
371
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 369

def create_time
  @create_time
end

#descriptionString

Optional. Description of the Automation. Max length is 255 characters. Corresponds to the JSON property description

Returns:

  • (String)


374
375
376
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 374

def description
  @description
end

#etagString

Optional. The weak etag of the Automation resource. 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

Returns:

  • (String)


382
383
384
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 382

def etag
  @etag
end

#labelsHash<String,String>

Optional. Labels are attributes that can be set and used by both the user and by Cloud Deploy. Labels must meet the following constraints: * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. * All characters must use UTF-8 encoding, and international characters are allowed. * Keys must start with a lowercase letter or international character. * Each resource is limited to a maximum of 64 labels. Both keys and values are additionally constrained to be <= 63 characters. Corresponds to the JSON property labels

Returns:

  • (Hash<String,String>)


393
394
395
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 393

def labels
  @labels
end

#nameString

Output only. Name of the Automation. Format is projects/project/locations/ location/deliveryPipelines/delivery_pipeline/automations/automation`. Corresponds to the JSON propertyname`

Returns:

  • (String)


399
400
401
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 399

def name
  @name
end

#rulesArray<Google::Apis::ClouddeployV1::AutomationRule>

Required. List of Automation rules associated with the Automation resource. Must have at least one rule and limited to 250 rules per Delivery Pipeline. Note: the order of the rules here is not the same as the order of execution. Corresponds to the JSON property rules



406
407
408
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 406

def rules
  @rules
end

#selectorGoogle::Apis::ClouddeployV1::AutomationResourceSelector

AutomationResourceSelector contains the information to select the resources to which an Automation is going to be applied. Corresponds to the JSON property selector



412
413
414
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 412

def selector
  @selector
end

#service_accountString

Required. Email address of the user-managed IAM service account that creates Cloud Deploy release and rollout resources. Corresponds to the JSON property serviceAccount

Returns:

  • (String)


418
419
420
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 418

def 
  @service_account
end

#suspendedBoolean Also known as: suspended?

Optional. When Suspended, automation is deactivated from execution. Corresponds to the JSON property suspended

Returns:

  • (Boolean)


423
424
425
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 423

def suspended
  @suspended
end

#uidString

Output only. Unique identifier of the Automation. Corresponds to the JSON property uid

Returns:

  • (String)


429
430
431
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 429

def uid
  @uid
end

#update_timeString

Output only. Time at which the automation was updated. Corresponds to the JSON property updateTime

Returns:

  • (String)


434
435
436
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 434

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



441
442
443
444
445
446
447
448
449
450
451
452
453
454
# File 'lib/google/apis/clouddeploy_v1/classes.rb', line 441

def update!(**args)
  @annotations = args[:annotations] if args.key?(:annotations)
  @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)
  @rules = args[:rules] if args.key?(:rules)
  @selector = args[:selector] if args.key?(:selector)
  @service_account = args[:service_account] if args.key?(:service_account)
  @suspended = args[:suspended] if args.key?(:suspended)
  @uid = args[:uid] if args.key?(:uid)
  @update_time = args[:update_time] if args.key?(:update_time)
end