google-apis-clouddeploy_v1 0.33.0 → 0.35.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.
@@ -89,6 +89,43 @@ module Google
89
89
  end
90
90
  end
91
91
 
92
+ # Contains the information of an automated advance-rollout operation.
93
+ class AdvanceRolloutOperation
94
+ include Google::Apis::Core::Hashable
95
+
96
+ # Output only. The phase to which the rollout will be advanced to.
97
+ # Corresponds to the JSON property `destinationPhase`
98
+ # @return [String]
99
+ attr_accessor :destination_phase
100
+
101
+ # Output only. The name of the rollout that initiates the `AutomationRun`.
102
+ # Corresponds to the JSON property `rollout`
103
+ # @return [String]
104
+ attr_accessor :rollout
105
+
106
+ # Output only. The phase of a deployment that initiated the operation.
107
+ # Corresponds to the JSON property `sourcePhase`
108
+ # @return [String]
109
+ attr_accessor :source_phase
110
+
111
+ # Output only. How long the operation will be paused.
112
+ # Corresponds to the JSON property `wait`
113
+ # @return [String]
114
+ attr_accessor :wait
115
+
116
+ def initialize(**args)
117
+ update!(**args)
118
+ end
119
+
120
+ # Update properties of this object
121
+ def update!(**args)
122
+ @destination_phase = args[:destination_phase] if args.key?(:destination_phase)
123
+ @rollout = args[:rollout] if args.key?(:rollout)
124
+ @source_phase = args[:source_phase] if args.key?(:source_phase)
125
+ @wait = args[:wait] if args.key?(:wait)
126
+ end
127
+ end
128
+
92
129
  # The request object used by `AdvanceRollout`.
93
130
  class AdvanceRolloutRequest
94
131
  include Google::Apis::Core::Hashable
@@ -121,6 +158,49 @@ module Google
121
158
  end
122
159
  end
123
160
 
161
+ # The `AdvanceRollout` automation rule will automatically advance a successful
162
+ # Rollout to the next phase.
163
+ class AdvanceRolloutRule
164
+ include Google::Apis::Core::Hashable
165
+
166
+ # `AutomationRuleCondition` contains conditions relevant to an `Automation` rule.
167
+ # Corresponds to the JSON property `condition`
168
+ # @return [Google::Apis::ClouddeployV1::AutomationRuleCondition]
169
+ attr_accessor :condition
170
+
171
+ # Required. ID of the rule. This id must be unique in the `Automation` resource
172
+ # to which this rule belongs. The format is a-z`0,62`.
173
+ # Corresponds to the JSON property `id`
174
+ # @return [String]
175
+ attr_accessor :id
176
+
177
+ # Optional. Proceeds only after phase name matched any one in the list. This
178
+ # value must consist of lower-case letters, numbers, and hyphens, start with a
179
+ # letter and end with a letter or a number, and have a max length of 63
180
+ # characters. In other words, it must match the following regex: `^[a-z]([a-z0-9-
181
+ # ]`0,61`[a-z0-9])?$`.
182
+ # Corresponds to the JSON property `sourcePhases`
183
+ # @return [Array<String>]
184
+ attr_accessor :source_phases
185
+
186
+ # Optional. How long to wait after a rollout is finished.
187
+ # Corresponds to the JSON property `wait`
188
+ # @return [String]
189
+ attr_accessor :wait
190
+
191
+ def initialize(**args)
192
+ update!(**args)
193
+ end
194
+
195
+ # Update properties of this object
196
+ def update!(**args)
197
+ @condition = args[:condition] if args.key?(:condition)
198
+ @id = args[:id] if args.key?(:id)
199
+ @source_phases = args[:source_phases] if args.key?(:source_phases)
200
+ @wait = args[:wait] if args.key?(:wait)
201
+ end
202
+ end
203
+
124
204
  # Information specifying an Anthos Cluster.
125
205
  class AnthosCluster
126
206
  include Google::Apis::Core::Hashable
@@ -246,6 +326,120 @@ module Google
246
326
  end
247
327
  end
248
328
 
329
+ # An `Automation` resource in the Cloud Deploy API. An `Automation` enables the
330
+ # automation of manually driven actions for a Delivery Pipeline, which includes
331
+ # Release promotion amongst Targets, Rollout repair and Rollout deployment
332
+ # strategy advancement. The intention of Automation is to reduce manual
333
+ # intervention in the continuous delivery process.
334
+ class Automation
335
+ include Google::Apis::Core::Hashable
336
+
337
+ # Optional. User annotations. These attributes can only be set and used by the
338
+ # user, and not by Cloud Deploy. Annotations must meet the following constraints:
339
+ # * Annotations are key/value pairs. * Valid annotation keys have two segments:
340
+ # an optional prefix and name, separated by a slash (/). * The name segment is
341
+ # required and must be 63 characters or less, beginning and ending with an
342
+ # alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_), dots (.)
343
+ # , and alphanumerics between. * The prefix is optional. If specified, the
344
+ # prefix must be a DNS subdomain: a series of DNS labels separated by dots(.),
345
+ # not longer than 253 characters in total, followed by a slash (/). See https://
346
+ # kubernetes.io/docs/concepts/overview/working-with-objects/annotations/#syntax-
347
+ # and-character-set for more details.
348
+ # Corresponds to the JSON property `annotations`
349
+ # @return [Hash<String,String>]
350
+ attr_accessor :annotations
351
+
352
+ # Output only. Time at which the automation was created.
353
+ # Corresponds to the JSON property `createTime`
354
+ # @return [String]
355
+ attr_accessor :create_time
356
+
357
+ # Optional. Description of the `Automation`. Max length is 255 characters.
358
+ # Corresponds to the JSON property `description`
359
+ # @return [String]
360
+ attr_accessor :description
361
+
362
+ # Optional. The weak etag of the `Automation` resource. This checksum is
363
+ # computed by the server based on the value of other fields, and may be sent on
364
+ # update and delete requests to ensure the client has an up-to-date value before
365
+ # proceeding.
366
+ # Corresponds to the JSON property `etag`
367
+ # @return [String]
368
+ attr_accessor :etag
369
+
370
+ # Optional. Labels are attributes that can be set and used by both the user and
371
+ # by Cloud Deploy. Labels must meet the following constraints: * Keys and values
372
+ # can contain only lowercase letters, numeric characters, underscores, and
373
+ # dashes. * All characters must use UTF-8 encoding, and international characters
374
+ # are allowed. * Keys must start with a lowercase letter or international
375
+ # character. * Each resource is limited to a maximum of 64 labels. Both keys and
376
+ # values are additionally constrained to be <= 63 characters.
377
+ # Corresponds to the JSON property `labels`
378
+ # @return [Hash<String,String>]
379
+ attr_accessor :labels
380
+
381
+ # Output only. Name of the `Automation`. Format is projects/`project`/locations/`
382
+ # location`/deliveryPipelines/`delivery_pipeline`/automations/`automation`.
383
+ # Corresponds to the JSON property `name`
384
+ # @return [String]
385
+ attr_accessor :name
386
+
387
+ # Required. List of Automation rules associated with the Automation resource.
388
+ # Must have at least one rule and limited to 250 rules per Delivery Pipeline.
389
+ # Note: the order of the rules here is not the same as the order of execution.
390
+ # Corresponds to the JSON property `rules`
391
+ # @return [Array<Google::Apis::ClouddeployV1::AutomationRule>]
392
+ attr_accessor :rules
393
+
394
+ # AutomationResourceSelector contains the information to select the resources to
395
+ # which an Automation is going to be applied.
396
+ # Corresponds to the JSON property `selector`
397
+ # @return [Google::Apis::ClouddeployV1::AutomationResourceSelector]
398
+ attr_accessor :selector
399
+
400
+ # Required. Email address of the user-managed IAM service account that creates
401
+ # Cloud Deploy release and rollout resources.
402
+ # Corresponds to the JSON property `serviceAccount`
403
+ # @return [String]
404
+ attr_accessor :service_account
405
+
406
+ # Optional. When Suspended, automation is deactivated from execution.
407
+ # Corresponds to the JSON property `suspended`
408
+ # @return [Boolean]
409
+ attr_accessor :suspended
410
+ alias_method :suspended?, :suspended
411
+
412
+ # Output only. Unique identifier of the `Automation`.
413
+ # Corresponds to the JSON property `uid`
414
+ # @return [String]
415
+ attr_accessor :uid
416
+
417
+ # Output only. Time at which the automation was updated.
418
+ # Corresponds to the JSON property `updateTime`
419
+ # @return [String]
420
+ attr_accessor :update_time
421
+
422
+ def initialize(**args)
423
+ update!(**args)
424
+ end
425
+
426
+ # Update properties of this object
427
+ def update!(**args)
428
+ @annotations = args[:annotations] if args.key?(:annotations)
429
+ @create_time = args[:create_time] if args.key?(:create_time)
430
+ @description = args[:description] if args.key?(:description)
431
+ @etag = args[:etag] if args.key?(:etag)
432
+ @labels = args[:labels] if args.key?(:labels)
433
+ @name = args[:name] if args.key?(:name)
434
+ @rules = args[:rules] if args.key?(:rules)
435
+ @selector = args[:selector] if args.key?(:selector)
436
+ @service_account = args[:service_account] if args.key?(:service_account)
437
+ @suspended = args[:suspended] if args.key?(:suspended)
438
+ @uid = args[:uid] if args.key?(:uid)
439
+ @update_time = args[:update_time] if args.key?(:update_time)
440
+ end
441
+ end
442
+
249
443
  # Payload proto for "clouddeploy.googleapis.com/automation" Platform Log event
250
444
  # that describes the Automation related events.
251
445
  class AutomationEvent
@@ -285,6 +479,238 @@ module Google
285
479
  end
286
480
  end
287
481
 
482
+ # AutomationResourceSelector contains the information to select the resources to
483
+ # which an Automation is going to be applied.
484
+ class AutomationResourceSelector
485
+ include Google::Apis::Core::Hashable
486
+
487
+ # Contains attributes about a target.
488
+ # Corresponds to the JSON property `targets`
489
+ # @return [Array<Google::Apis::ClouddeployV1::TargetAttribute>]
490
+ attr_accessor :targets
491
+
492
+ def initialize(**args)
493
+ update!(**args)
494
+ end
495
+
496
+ # Update properties of this object
497
+ def update!(**args)
498
+ @targets = args[:targets] if args.key?(:targets)
499
+ end
500
+ end
501
+
502
+ # AutomationRolloutMetadata contains Automation-related actions that were
503
+ # performed on a rollout.
504
+ class AutomationRolloutMetadata
505
+ include Google::Apis::Core::Hashable
506
+
507
+ # Output only. The IDs of the AutomationRuns initiated by an advance rollout
508
+ # rule.
509
+ # Corresponds to the JSON property `advanceAutomationRuns`
510
+ # @return [Array<String>]
511
+ attr_accessor :advance_automation_runs
512
+
513
+ # Output only. The ID of the AutomationRun initiated by a promote release rule.
514
+ # Corresponds to the JSON property `promoteAutomationRun`
515
+ # @return [String]
516
+ attr_accessor :promote_automation_run
517
+
518
+ # Output only. The IDs of the AutomationRuns initiated by a repair rollout rule.
519
+ # Corresponds to the JSON property `repairAutomationRuns`
520
+ # @return [Array<String>]
521
+ attr_accessor :repair_automation_runs
522
+
523
+ def initialize(**args)
524
+ update!(**args)
525
+ end
526
+
527
+ # Update properties of this object
528
+ def update!(**args)
529
+ @advance_automation_runs = args[:advance_automation_runs] if args.key?(:advance_automation_runs)
530
+ @promote_automation_run = args[:promote_automation_run] if args.key?(:promote_automation_run)
531
+ @repair_automation_runs = args[:repair_automation_runs] if args.key?(:repair_automation_runs)
532
+ end
533
+ end
534
+
535
+ # `AutomationRule` defines the automation activities.
536
+ class AutomationRule
537
+ include Google::Apis::Core::Hashable
538
+
539
+ # The `AdvanceRollout` automation rule will automatically advance a successful
540
+ # Rollout to the next phase.
541
+ # Corresponds to the JSON property `advanceRolloutRule`
542
+ # @return [Google::Apis::ClouddeployV1::AdvanceRolloutRule]
543
+ attr_accessor :advance_rollout_rule
544
+
545
+ # `PromoteRelease` rule will automatically promote a release from the current
546
+ # target to a specified target.
547
+ # Corresponds to the JSON property `promoteReleaseRule`
548
+ # @return [Google::Apis::ClouddeployV1::PromoteReleaseRule]
549
+ attr_accessor :promote_release_rule
550
+
551
+ # The `RepairRolloutRule` automation rule will automatically repair a failed `
552
+ # Rollout`.
553
+ # Corresponds to the JSON property `repairRolloutRule`
554
+ # @return [Google::Apis::ClouddeployV1::RepairRolloutRule]
555
+ attr_accessor :repair_rollout_rule
556
+
557
+ def initialize(**args)
558
+ update!(**args)
559
+ end
560
+
561
+ # Update properties of this object
562
+ def update!(**args)
563
+ @advance_rollout_rule = args[:advance_rollout_rule] if args.key?(:advance_rollout_rule)
564
+ @promote_release_rule = args[:promote_release_rule] if args.key?(:promote_release_rule)
565
+ @repair_rollout_rule = args[:repair_rollout_rule] if args.key?(:repair_rollout_rule)
566
+ end
567
+ end
568
+
569
+ # `AutomationRuleCondition` contains conditions relevant to an `Automation` rule.
570
+ class AutomationRuleCondition
571
+ include Google::Apis::Core::Hashable
572
+
573
+ # TargetsPresentCondition contains information on any Targets defined in the
574
+ # Delivery Pipeline that do not actually exist.
575
+ # Corresponds to the JSON property `targetsPresentCondition`
576
+ # @return [Google::Apis::ClouddeployV1::TargetsPresentCondition]
577
+ attr_accessor :targets_present_condition
578
+
579
+ def initialize(**args)
580
+ update!(**args)
581
+ end
582
+
583
+ # Update properties of this object
584
+ def update!(**args)
585
+ @targets_present_condition = args[:targets_present_condition] if args.key?(:targets_present_condition)
586
+ end
587
+ end
588
+
589
+ # An `AutomationRun` resource in the Cloud Deploy API. An `AutomationResource`
590
+ # represents an automation execution instance of an automation rule.
591
+ class AutomationRun
592
+ include Google::Apis::Core::Hashable
593
+
594
+ # Contains the information of an automated advance-rollout operation.
595
+ # Corresponds to the JSON property `advanceRolloutOperation`
596
+ # @return [Google::Apis::ClouddeployV1::AdvanceRolloutOperation]
597
+ attr_accessor :advance_rollout_operation
598
+
599
+ # Output only. The ID of the automation that initiated the operation.
600
+ # Corresponds to the JSON property `automationId`
601
+ # @return [String]
602
+ attr_accessor :automation_id
603
+
604
+ # An `Automation` resource in the Cloud Deploy API. An `Automation` enables the
605
+ # automation of manually driven actions for a Delivery Pipeline, which includes
606
+ # Release promotion amongst Targets, Rollout repair and Rollout deployment
607
+ # strategy advancement. The intention of Automation is to reduce manual
608
+ # intervention in the continuous delivery process.
609
+ # Corresponds to the JSON property `automationSnapshot`
610
+ # @return [Google::Apis::ClouddeployV1::Automation]
611
+ attr_accessor :automation_snapshot
612
+
613
+ # Output only. Time at which the `AutomationRun` was created.
614
+ # Corresponds to the JSON property `createTime`
615
+ # @return [String]
616
+ attr_accessor :create_time
617
+
618
+ # Output only. The weak etag of the `AutomationRun` resource. This checksum is
619
+ # computed by the server based on the value of other fields, and may be sent on
620
+ # update and delete requests to ensure the client has an up-to-date value before
621
+ # proceeding.
622
+ # Corresponds to the JSON property `etag`
623
+ # @return [String]
624
+ attr_accessor :etag
625
+
626
+ # Output only. Time the `AutomationRun` will expire. An `AutomationRun` will
627
+ # expire after 14 days from its creation date.
628
+ # Corresponds to the JSON property `expireTime`
629
+ # @return [String]
630
+ attr_accessor :expire_time
631
+
632
+ # Output only. Name of the `AutomationRun`. Format is projects/`project`/
633
+ # locations/`location`/deliveryPipelines/`delivery_pipeline`/automationRuns/`
634
+ # automation_run`.
635
+ # Corresponds to the JSON property `name`
636
+ # @return [String]
637
+ attr_accessor :name
638
+
639
+ # Contains the information of an automated promote-release operation.
640
+ # Corresponds to the JSON property `promoteReleaseOperation`
641
+ # @return [Google::Apis::ClouddeployV1::PromoteReleaseOperation]
642
+ attr_accessor :promote_release_operation
643
+
644
+ # Contains the information for an automated `repair rollout` operation.
645
+ # Corresponds to the JSON property `repairRolloutOperation`
646
+ # @return [Google::Apis::ClouddeployV1::RepairRolloutOperation]
647
+ attr_accessor :repair_rollout_operation
648
+
649
+ # Output only. The ID of the automation rule that initiated the operation.
650
+ # Corresponds to the JSON property `ruleId`
651
+ # @return [String]
652
+ attr_accessor :rule_id
653
+
654
+ # Output only. Email address of the user-managed IAM service account that
655
+ # performs the operations against Cloud Deploy resources.
656
+ # Corresponds to the JSON property `serviceAccount`
657
+ # @return [String]
658
+ attr_accessor :service_account
659
+
660
+ # Output only. Current state of the `AutomationRun`.
661
+ # Corresponds to the JSON property `state`
662
+ # @return [String]
663
+ attr_accessor :state
664
+
665
+ # Output only. Explains the current state of the `AutomationRun`. Present only
666
+ # an explanation is needed.
667
+ # Corresponds to the JSON property `stateDescription`
668
+ # @return [String]
669
+ attr_accessor :state_description
670
+
671
+ # Output only. The ID of the target that represents the promotion stage that
672
+ # initiates the `AutomationRun`. The value of this field is the last segment of
673
+ # a target name.
674
+ # Corresponds to the JSON property `targetId`
675
+ # @return [String]
676
+ attr_accessor :target_id
677
+
678
+ # Output only. Time at which the automationRun was updated.
679
+ # Corresponds to the JSON property `updateTime`
680
+ # @return [String]
681
+ attr_accessor :update_time
682
+
683
+ # Output only. Earliest time the `AutomationRun` will attempt to resume. Wait-
684
+ # time is configured by `wait` in automation rule.
685
+ # Corresponds to the JSON property `waitUntilTime`
686
+ # @return [String]
687
+ attr_accessor :wait_until_time
688
+
689
+ def initialize(**args)
690
+ update!(**args)
691
+ end
692
+
693
+ # Update properties of this object
694
+ def update!(**args)
695
+ @advance_rollout_operation = args[:advance_rollout_operation] if args.key?(:advance_rollout_operation)
696
+ @automation_id = args[:automation_id] if args.key?(:automation_id)
697
+ @automation_snapshot = args[:automation_snapshot] if args.key?(:automation_snapshot)
698
+ @create_time = args[:create_time] if args.key?(:create_time)
699
+ @etag = args[:etag] if args.key?(:etag)
700
+ @expire_time = args[:expire_time] if args.key?(:expire_time)
701
+ @name = args[:name] if args.key?(:name)
702
+ @promote_release_operation = args[:promote_release_operation] if args.key?(:promote_release_operation)
703
+ @repair_rollout_operation = args[:repair_rollout_operation] if args.key?(:repair_rollout_operation)
704
+ @rule_id = args[:rule_id] if args.key?(:rule_id)
705
+ @service_account = args[:service_account] if args.key?(:service_account)
706
+ @state = args[:state] if args.key?(:state)
707
+ @state_description = args[:state_description] if args.key?(:state_description)
708
+ @target_id = args[:target_id] if args.key?(:target_id)
709
+ @update_time = args[:update_time] if args.key?(:update_time)
710
+ @wait_until_time = args[:wait_until_time] if args.key?(:wait_until_time)
711
+ end
712
+ end
713
+
288
714
  # Payload proto for "clouddeploy.googleapis.com/automation_run" Platform Log
289
715
  # event that describes the AutomationRun related events.
290
716
  class AutomationRunEvent
@@ -516,6 +942,32 @@ module Google
516
942
  end
517
943
  end
518
944
 
945
+ # The request object used by `CancelAutomationRun`.
946
+ class CancelAutomationRunRequest
947
+ include Google::Apis::Core::Hashable
948
+
949
+ def initialize(**args)
950
+ update!(**args)
951
+ end
952
+
953
+ # Update properties of this object
954
+ def update!(**args)
955
+ end
956
+ end
957
+
958
+ # The response object from `CancelAutomationRun`.
959
+ class CancelAutomationRunResponse
960
+ include Google::Apis::Core::Hashable
961
+
962
+ def initialize(**args)
963
+ update!(**args)
964
+ end
965
+
966
+ # Update properties of this object
967
+ def update!(**args)
968
+ end
969
+ end
970
+
519
971
  # The request message for Operations.CancelOperation.
520
972
  class CancelOperationRequest
521
973
  include Google::Apis::Core::Hashable
@@ -1651,6 +2103,70 @@ module Google
1651
2103
  end
1652
2104
  end
1653
2105
 
2106
+ # The response object from `ListAutomationRuns`.
2107
+ class ListAutomationRunsResponse
2108
+ include Google::Apis::Core::Hashable
2109
+
2110
+ # The `AutomationRuns` objects.
2111
+ # Corresponds to the JSON property `automationRuns`
2112
+ # @return [Array<Google::Apis::ClouddeployV1::AutomationRun>]
2113
+ attr_accessor :automation_runs
2114
+
2115
+ # A token, which can be sent as `page_token` to retrieve the next page. If this
2116
+ # field is omitted, there are no subsequent pages.
2117
+ # Corresponds to the JSON property `nextPageToken`
2118
+ # @return [String]
2119
+ attr_accessor :next_page_token
2120
+
2121
+ # Locations that could not be reached.
2122
+ # Corresponds to the JSON property `unreachable`
2123
+ # @return [Array<String>]
2124
+ attr_accessor :unreachable
2125
+
2126
+ def initialize(**args)
2127
+ update!(**args)
2128
+ end
2129
+
2130
+ # Update properties of this object
2131
+ def update!(**args)
2132
+ @automation_runs = args[:automation_runs] if args.key?(:automation_runs)
2133
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
2134
+ @unreachable = args[:unreachable] if args.key?(:unreachable)
2135
+ end
2136
+ end
2137
+
2138
+ # The response object from `ListAutomations`.
2139
+ class ListAutomationsResponse
2140
+ include Google::Apis::Core::Hashable
2141
+
2142
+ # The `Automations` objects.
2143
+ # Corresponds to the JSON property `automations`
2144
+ # @return [Array<Google::Apis::ClouddeployV1::Automation>]
2145
+ attr_accessor :automations
2146
+
2147
+ # A token, which can be sent as `page_token` to retrieve the next page. If this
2148
+ # field is omitted, there are no subsequent pages.
2149
+ # Corresponds to the JSON property `nextPageToken`
2150
+ # @return [String]
2151
+ attr_accessor :next_page_token
2152
+
2153
+ # Locations that could not be reached.
2154
+ # Corresponds to the JSON property `unreachable`
2155
+ # @return [Array<String>]
2156
+ attr_accessor :unreachable
2157
+
2158
+ def initialize(**args)
2159
+ update!(**args)
2160
+ end
2161
+
2162
+ # Update properties of this object
2163
+ def update!(**args)
2164
+ @automations = args[:automations] if args.key?(:automations)
2165
+ @next_page_token = args[:next_page_token] if args.key?(:next_page_token)
2166
+ @unreachable = args[:unreachable] if args.key?(:unreachable)
2167
+ end
2168
+ end
2169
+
1654
2170
  # The response object from `ListDeliveryPipelines`.
1655
2171
  class ListDeliveryPipelinesResponse
1656
2172
  include Google::Apis::Core::Hashable
@@ -1912,6 +2428,12 @@ module Google
1912
2428
  class Metadata
1913
2429
  include Google::Apis::Core::Hashable
1914
2430
 
2431
+ # AutomationRolloutMetadata contains Automation-related actions that were
2432
+ # performed on a rollout.
2433
+ # Corresponds to the JSON property `automation`
2434
+ # @return [Google::Apis::ClouddeployV1::AutomationRolloutMetadata]
2435
+ attr_accessor :automation
2436
+
1915
2437
  # CloudRunMetadata contains information from a Cloud Run deployment.
1916
2438
  # Corresponds to the JSON property `cloudRun`
1917
2439
  # @return [Google::Apis::ClouddeployV1::CloudRunMetadata]
@@ -1923,6 +2445,7 @@ module Google
1923
2445
 
1924
2446
  # Update properties of this object
1925
2447
  def update!(**args)
2448
+ @automation = args[:automation] if args.key?(:automation)
1926
2449
  @cloud_run = args[:cloud_run] if args.key?(:cloud_run)
1927
2450
  end
1928
2451
  end
@@ -2519,13 +3042,102 @@ module Google
2519
3042
  # will be used.
2520
3043
  # Corresponds to the JSON property `serviceAccount`
2521
3044
  # @return [String]
2522
- attr_accessor :service_account
3045
+ attr_accessor :service_account
3046
+
3047
+ # Required. Resource name of the Cloud Build worker pool to use. The format is `
3048
+ # projects/`project`/locations/`location`/workerPools/`pool``.
3049
+ # Corresponds to the JSON property `workerPool`
3050
+ # @return [String]
3051
+ attr_accessor :worker_pool
3052
+
3053
+ def initialize(**args)
3054
+ update!(**args)
3055
+ end
3056
+
3057
+ # Update properties of this object
3058
+ def update!(**args)
3059
+ @artifact_storage = args[:artifact_storage] if args.key?(:artifact_storage)
3060
+ @service_account = args[:service_account] if args.key?(:service_account)
3061
+ @worker_pool = args[:worker_pool] if args.key?(:worker_pool)
3062
+ end
3063
+ end
3064
+
3065
+ # Contains the information of an automated promote-release operation.
3066
+ class PromoteReleaseOperation
3067
+ include Google::Apis::Core::Hashable
3068
+
3069
+ # Output only. The starting phase of the rollout created by this operation.
3070
+ # Corresponds to the JSON property `phase`
3071
+ # @return [String]
3072
+ attr_accessor :phase
3073
+
3074
+ # Output only. The name of the rollout that initiates the `AutomationRun`.
3075
+ # Corresponds to the JSON property `rollout`
3076
+ # @return [String]
3077
+ attr_accessor :rollout
3078
+
3079
+ # Output only. The ID of the target that represents the promotion stage to which
3080
+ # the release will be promoted. The value of this field is the last segment of a
3081
+ # target name.
3082
+ # Corresponds to the JSON property `targetId`
3083
+ # @return [String]
3084
+ attr_accessor :target_id
3085
+
3086
+ # Output only. How long the operation will be paused.
3087
+ # Corresponds to the JSON property `wait`
3088
+ # @return [String]
3089
+ attr_accessor :wait
3090
+
3091
+ def initialize(**args)
3092
+ update!(**args)
3093
+ end
3094
+
3095
+ # Update properties of this object
3096
+ def update!(**args)
3097
+ @phase = args[:phase] if args.key?(:phase)
3098
+ @rollout = args[:rollout] if args.key?(:rollout)
3099
+ @target_id = args[:target_id] if args.key?(:target_id)
3100
+ @wait = args[:wait] if args.key?(:wait)
3101
+ end
3102
+ end
3103
+
3104
+ # `PromoteRelease` rule will automatically promote a release from the current
3105
+ # target to a specified target.
3106
+ class PromoteReleaseRule
3107
+ include Google::Apis::Core::Hashable
3108
+
3109
+ # `AutomationRuleCondition` contains conditions relevant to an `Automation` rule.
3110
+ # Corresponds to the JSON property `condition`
3111
+ # @return [Google::Apis::ClouddeployV1::AutomationRuleCondition]
3112
+ attr_accessor :condition
3113
+
3114
+ # Optional. The starting phase of the rollout created by this operation. Default
3115
+ # to the first phase.
3116
+ # Corresponds to the JSON property `destinationPhase`
3117
+ # @return [String]
3118
+ attr_accessor :destination_phase
3119
+
3120
+ # Optional. The ID of the stage in the pipeline to which this `Release` is
3121
+ # deploying. If unspecified, default it to the next stage in the promotion flow.
3122
+ # The value of this field could be one of the following: * The last segment of a
3123
+ # target name. It only needs the ID to determine if the target is one of the
3124
+ # stages in the promotion sequence defined in the pipeline. * "@next", the next
3125
+ # target in the promotion sequence.
3126
+ # Corresponds to the JSON property `destinationTargetId`
3127
+ # @return [String]
3128
+ attr_accessor :destination_target_id
2523
3129
 
2524
- # Required. Resource name of the Cloud Build worker pool to use. The format is `
2525
- # projects/`project`/locations/`location`/workerPools/`pool``.
2526
- # Corresponds to the JSON property `workerPool`
3130
+ # Required. ID of the rule. This id must be unique in the `Automation` resource
3131
+ # to which this rule belongs. The format is a-z`0,62`.
3132
+ # Corresponds to the JSON property `id`
2527
3133
  # @return [String]
2528
- attr_accessor :worker_pool
3134
+ attr_accessor :id
3135
+
3136
+ # Optional. How long the release need to be paused until being promoted to the
3137
+ # next target.
3138
+ # Corresponds to the JSON property `wait`
3139
+ # @return [String]
3140
+ attr_accessor :wait
2529
3141
 
2530
3142
  def initialize(**args)
2531
3143
  update!(**args)
@@ -2533,9 +3145,11 @@ module Google
2533
3145
 
2534
3146
  # Update properties of this object
2535
3147
  def update!(**args)
2536
- @artifact_storage = args[:artifact_storage] if args.key?(:artifact_storage)
2537
- @service_account = args[:service_account] if args.key?(:service_account)
2538
- @worker_pool = args[:worker_pool] if args.key?(:worker_pool)
3148
+ @condition = args[:condition] if args.key?(:condition)
3149
+ @destination_phase = args[:destination_phase] if args.key?(:destination_phase)
3150
+ @destination_target_id = args[:destination_target_id] if args.key?(:destination_target_id)
3151
+ @id = args[:id] if args.key?(:id)
3152
+ @wait = args[:wait] if args.key?(:wait)
2539
3153
  end
2540
3154
  end
2541
3155
 
@@ -2791,11 +3405,16 @@ module Google
2791
3405
  # @return [String]
2792
3406
  attr_accessor :message
2793
3407
 
2794
- # The name of the `Release`.
3408
+ # The name of the release.
2795
3409
  # Corresponds to the JSON property `release`
2796
3410
  # @return [String]
2797
3411
  attr_accessor :release
2798
3412
 
3413
+ # The state of the release render.
3414
+ # Corresponds to the JSON property `releaseRenderState`
3415
+ # @return [String]
3416
+ attr_accessor :release_render_state
3417
+
2799
3418
  def initialize(**args)
2800
3419
  update!(**args)
2801
3420
  end
@@ -2804,6 +3423,7 @@ module Google
2804
3423
  def update!(**args)
2805
3424
  @message = args[:message] if args.key?(:message)
2806
3425
  @release = args[:release] if args.key?(:release)
3426
+ @release_render_state = args[:release_render_state] if args.key?(:release_render_state)
2807
3427
  end
2808
3428
  end
2809
3429
 
@@ -2827,6 +3447,216 @@ module Google
2827
3447
  end
2828
3448
  end
2829
3449
 
3450
+ # Configuration of the repair action.
3451
+ class RepairMode
3452
+ include Google::Apis::Core::Hashable
3453
+
3454
+ # Retries the failed job.
3455
+ # Corresponds to the JSON property `retry`
3456
+ # @return [Google::Apis::ClouddeployV1::Retry]
3457
+ attr_accessor :retry
3458
+
3459
+ # Rolls back a `Rollout`.
3460
+ # Corresponds to the JSON property `rollback`
3461
+ # @return [Google::Apis::ClouddeployV1::Rollback]
3462
+ attr_accessor :rollback
3463
+
3464
+ def initialize(**args)
3465
+ update!(**args)
3466
+ end
3467
+
3468
+ # Update properties of this object
3469
+ def update!(**args)
3470
+ @retry = args[:retry] if args.key?(:retry)
3471
+ @rollback = args[:rollback] if args.key?(:rollback)
3472
+ end
3473
+ end
3474
+
3475
+ # RepairPhase tracks the repair attempts that have been made for each `
3476
+ # RepairMode` specified in the `Automation` resource.
3477
+ class RepairPhase
3478
+ include Google::Apis::Core::Hashable
3479
+
3480
+ # RetryPhase contains the retry attempts and the metadata for initiating a new
3481
+ # attempt.
3482
+ # Corresponds to the JSON property `retry`
3483
+ # @return [Google::Apis::ClouddeployV1::RetryPhase]
3484
+ attr_accessor :retry
3485
+
3486
+ # RollbackAttempt represents an action of rolling back a Cloud Deploy 'Target'.
3487
+ # Corresponds to the JSON property `rollback`
3488
+ # @return [Google::Apis::ClouddeployV1::RollbackAttempt]
3489
+ attr_accessor :rollback
3490
+
3491
+ def initialize(**args)
3492
+ update!(**args)
3493
+ end
3494
+
3495
+ # Update properties of this object
3496
+ def update!(**args)
3497
+ @retry = args[:retry] if args.key?(:retry)
3498
+ @rollback = args[:rollback] if args.key?(:rollback)
3499
+ end
3500
+ end
3501
+
3502
+ # Contains the information for an automated `repair rollout` operation.
3503
+ class RepairRolloutOperation
3504
+ include Google::Apis::Core::Hashable
3505
+
3506
+ # Output only. The index of the current repair action in the repair sequence.
3507
+ # Corresponds to the JSON property `currentRepairModeIndex`
3508
+ # @return [Fixnum]
3509
+ attr_accessor :current_repair_mode_index
3510
+
3511
+ # Output only. Records of the repair attempts. Each repair phase may have
3512
+ # multiple retry attempts or single rollback attempt.
3513
+ # Corresponds to the JSON property `repairPhases`
3514
+ # @return [Array<Google::Apis::ClouddeployV1::RepairPhase>]
3515
+ attr_accessor :repair_phases
3516
+
3517
+ # Output only. The name of the rollout that initiates the `AutomationRun`.
3518
+ # Corresponds to the JSON property `rollout`
3519
+ # @return [String]
3520
+ attr_accessor :rollout
3521
+
3522
+ def initialize(**args)
3523
+ update!(**args)
3524
+ end
3525
+
3526
+ # Update properties of this object
3527
+ def update!(**args)
3528
+ @current_repair_mode_index = args[:current_repair_mode_index] if args.key?(:current_repair_mode_index)
3529
+ @repair_phases = args[:repair_phases] if args.key?(:repair_phases)
3530
+ @rollout = args[:rollout] if args.key?(:rollout)
3531
+ end
3532
+ end
3533
+
3534
+ # The `RepairRolloutRule` automation rule will automatically repair a failed `
3535
+ # Rollout`.
3536
+ class RepairRolloutRule
3537
+ include Google::Apis::Core::Hashable
3538
+
3539
+ # `AutomationRuleCondition` contains conditions relevant to an `Automation` rule.
3540
+ # Corresponds to the JSON property `condition`
3541
+ # @return [Google::Apis::ClouddeployV1::AutomationRuleCondition]
3542
+ attr_accessor :condition
3543
+
3544
+ # Required. ID of the rule. This id must be unique in the `Automation` resource
3545
+ # to which this rule belongs. The format is a-z`0,62`.
3546
+ # Corresponds to the JSON property `id`
3547
+ # @return [String]
3548
+ attr_accessor :id
3549
+
3550
+ # Optional. Jobs to repair. Proceeds only after job name matched any one in the
3551
+ # list, or for all jobs if unspecified or empty. The phase that includes the job
3552
+ # must match the phase ID specified in `source_phase`. This value must consist
3553
+ # of lower-case letters, numbers, and hyphens, start with a letter and end with
3554
+ # a letter or a number, and have a max length of 63 characters. In other words,
3555
+ # it must match the following regex: `^[a-z]([a-z0-9-]`0,61`[a-z0-9])?$`.
3556
+ # Corresponds to the JSON property `jobs`
3557
+ # @return [Array<String>]
3558
+ attr_accessor :jobs
3559
+
3560
+ # Required. Defines the types of automatic repair actions for failed jobs.
3561
+ # Corresponds to the JSON property `repairModes`
3562
+ # @return [Array<Google::Apis::ClouddeployV1::RepairMode>]
3563
+ attr_accessor :repair_modes
3564
+
3565
+ # Optional. Phases within which jobs are subject to automatic repair actions on
3566
+ # failure. Proceeds only after phase name matched any one in the list, or for
3567
+ # all phases if unspecified. This value must consist of lower-case letters,
3568
+ # numbers, and hyphens, start with a letter and end with a letter or a number,
3569
+ # and have a max length of 63 characters. In other words, it must match the
3570
+ # following regex: `^[a-z]([a-z0-9-]`0,61`[a-z0-9])?$`.
3571
+ # Corresponds to the JSON property `sourcePhases`
3572
+ # @return [Array<String>]
3573
+ attr_accessor :source_phases
3574
+
3575
+ def initialize(**args)
3576
+ update!(**args)
3577
+ end
3578
+
3579
+ # Update properties of this object
3580
+ def update!(**args)
3581
+ @condition = args[:condition] if args.key?(:condition)
3582
+ @id = args[:id] if args.key?(:id)
3583
+ @jobs = args[:jobs] if args.key?(:jobs)
3584
+ @repair_modes = args[:repair_modes] if args.key?(:repair_modes)
3585
+ @source_phases = args[:source_phases] if args.key?(:source_phases)
3586
+ end
3587
+ end
3588
+
3589
+ # Retries the failed job.
3590
+ class Retry
3591
+ include Google::Apis::Core::Hashable
3592
+
3593
+ # Required. Total number of retries. Retry will skipped if set to 0; The minimum
3594
+ # value is 1, and the maximum value is 10.
3595
+ # Corresponds to the JSON property `attempts`
3596
+ # @return [Fixnum]
3597
+ attr_accessor :attempts
3598
+
3599
+ # Optional. The pattern of how wait time will be increased. Default is linear.
3600
+ # Backoff mode will be ignored if `wait` is 0.
3601
+ # Corresponds to the JSON property `backoffMode`
3602
+ # @return [String]
3603
+ attr_accessor :backoff_mode
3604
+
3605
+ # Optional. How long to wait for the first retry. Default is 0, and the maximum
3606
+ # value is 14d.
3607
+ # Corresponds to the JSON property `wait`
3608
+ # @return [String]
3609
+ attr_accessor :wait
3610
+
3611
+ def initialize(**args)
3612
+ update!(**args)
3613
+ end
3614
+
3615
+ # Update properties of this object
3616
+ def update!(**args)
3617
+ @attempts = args[:attempts] if args.key?(:attempts)
3618
+ @backoff_mode = args[:backoff_mode] if args.key?(:backoff_mode)
3619
+ @wait = args[:wait] if args.key?(:wait)
3620
+ end
3621
+ end
3622
+
3623
+ # RetryAttempt represents an action of retrying the failed Cloud Deploy job.
3624
+ class RetryAttempt
3625
+ include Google::Apis::Core::Hashable
3626
+
3627
+ # Output only. The index of this retry attempt.
3628
+ # Corresponds to the JSON property `attempt`
3629
+ # @return [Fixnum]
3630
+ attr_accessor :attempt
3631
+
3632
+ # Output only. Valid state of this retry action.
3633
+ # Corresponds to the JSON property `state`
3634
+ # @return [String]
3635
+ attr_accessor :state
3636
+
3637
+ # Output only. Description of the state of the Retry.
3638
+ # Corresponds to the JSON property `stateDesc`
3639
+ # @return [String]
3640
+ attr_accessor :state_desc
3641
+
3642
+ # Output only. How long the operation will be paused.
3643
+ # Corresponds to the JSON property `wait`
3644
+ # @return [String]
3645
+ attr_accessor :wait
3646
+
3647
+ def initialize(**args)
3648
+ update!(**args)
3649
+ end
3650
+
3651
+ # Update properties of this object
3652
+ def update!(**args)
3653
+ @attempt = args[:attempt] if args.key?(:attempt)
3654
+ @state = args[:state] if args.key?(:state)
3655
+ @state_desc = args[:state_desc] if args.key?(:state_desc)
3656
+ @wait = args[:wait] if args.key?(:wait)
3657
+ end
3658
+ end
3659
+
2830
3660
  # RetryJobRequest is the request object used by `RetryJob`.
2831
3661
  class RetryJobRequest
2832
3662
  include Google::Apis::Core::Hashable
@@ -2865,6 +3695,108 @@ module Google
2865
3695
  end
2866
3696
  end
2867
3697
 
3698
+ # RetryPhase contains the retry attempts and the metadata for initiating a new
3699
+ # attempt.
3700
+ class RetryPhase
3701
+ include Google::Apis::Core::Hashable
3702
+
3703
+ # Output only. Detail of a retry action.
3704
+ # Corresponds to the JSON property `attempts`
3705
+ # @return [Array<Google::Apis::ClouddeployV1::RetryAttempt>]
3706
+ attr_accessor :attempts
3707
+
3708
+ # Output only. The pattern of how the wait time of the retry attempt is
3709
+ # calculated.
3710
+ # Corresponds to the JSON property `backoffMode`
3711
+ # @return [String]
3712
+ attr_accessor :backoff_mode
3713
+
3714
+ # Output only. The job ID for the Job to retry.
3715
+ # Corresponds to the JSON property `jobId`
3716
+ # @return [String]
3717
+ attr_accessor :job_id
3718
+
3719
+ # Output only. The phase ID of the phase that includes the job being retried.
3720
+ # Corresponds to the JSON property `phaseId`
3721
+ # @return [String]
3722
+ attr_accessor :phase_id
3723
+
3724
+ # Output only. The number of attempts that have been made.
3725
+ # Corresponds to the JSON property `totalAttempts`
3726
+ # @return [Fixnum]
3727
+ attr_accessor :total_attempts
3728
+
3729
+ def initialize(**args)
3730
+ update!(**args)
3731
+ end
3732
+
3733
+ # Update properties of this object
3734
+ def update!(**args)
3735
+ @attempts = args[:attempts] if args.key?(:attempts)
3736
+ @backoff_mode = args[:backoff_mode] if args.key?(:backoff_mode)
3737
+ @job_id = args[:job_id] if args.key?(:job_id)
3738
+ @phase_id = args[:phase_id] if args.key?(:phase_id)
3739
+ @total_attempts = args[:total_attempts] if args.key?(:total_attempts)
3740
+ end
3741
+ end
3742
+
3743
+ # Rolls back a `Rollout`.
3744
+ class Rollback
3745
+ include Google::Apis::Core::Hashable
3746
+
3747
+ # Optional. The starting phase ID for the `Rollout`. If unspecified, the `
3748
+ # Rollout` will start in the stable phase.
3749
+ # Corresponds to the JSON property `destinationPhase`
3750
+ # @return [String]
3751
+ attr_accessor :destination_phase
3752
+
3753
+ def initialize(**args)
3754
+ update!(**args)
3755
+ end
3756
+
3757
+ # Update properties of this object
3758
+ def update!(**args)
3759
+ @destination_phase = args[:destination_phase] if args.key?(:destination_phase)
3760
+ end
3761
+ end
3762
+
3763
+ # RollbackAttempt represents an action of rolling back a Cloud Deploy 'Target'.
3764
+ class RollbackAttempt
3765
+ include Google::Apis::Core::Hashable
3766
+
3767
+ # Output only. The phase to which the rollout will be rolled back to.
3768
+ # Corresponds to the JSON property `destinationPhase`
3769
+ # @return [String]
3770
+ attr_accessor :destination_phase
3771
+
3772
+ # Output only. ID of the rollback `Rollout` to create.
3773
+ # Corresponds to the JSON property `rolloutId`
3774
+ # @return [String]
3775
+ attr_accessor :rollout_id
3776
+
3777
+ # Output only. Valid state of this rollback action.
3778
+ # Corresponds to the JSON property `state`
3779
+ # @return [String]
3780
+ attr_accessor :state
3781
+
3782
+ # Output only. Description of the state of the Rollback.
3783
+ # Corresponds to the JSON property `stateDesc`
3784
+ # @return [String]
3785
+ attr_accessor :state_desc
3786
+
3787
+ def initialize(**args)
3788
+ update!(**args)
3789
+ end
3790
+
3791
+ # Update properties of this object
3792
+ def update!(**args)
3793
+ @destination_phase = args[:destination_phase] if args.key?(:destination_phase)
3794
+ @rollout_id = args[:rollout_id] if args.key?(:rollout_id)
3795
+ @state = args[:state] if args.key?(:state)
3796
+ @state_desc = args[:state_desc] if args.key?(:state_desc)
3797
+ end
3798
+ end
3799
+
2868
3800
  # Configs for the Rollback rollout.
2869
3801
  class RollbackTargetConfig
2870
3802
  include Google::Apis::Core::Hashable
@@ -3180,6 +4112,62 @@ module Google
3180
4112
  end
3181
4113
  end
3182
4114
 
4115
+ # Payload proto for "clouddeploy.googleapis.com/rollout_update" Platform Log
4116
+ # event that describes the rollout update event.
4117
+ class RolloutUpdateEvent
4118
+ include Google::Apis::Core::Hashable
4119
+
4120
+ # Debug message for when a rollout update event occurs.
4121
+ # Corresponds to the JSON property `message`
4122
+ # @return [String]
4123
+ attr_accessor :message
4124
+
4125
+ # Unique identifier of the pipeline.
4126
+ # Corresponds to the JSON property `pipelineUid`
4127
+ # @return [String]
4128
+ attr_accessor :pipeline_uid
4129
+
4130
+ # Unique identifier of the release.
4131
+ # Corresponds to the JSON property `releaseUid`
4132
+ # @return [String]
4133
+ attr_accessor :release_uid
4134
+
4135
+ # The name of the rollout.
4136
+ # Corresponds to the JSON property `rollout`
4137
+ # @return [String]
4138
+ attr_accessor :rollout
4139
+
4140
+ # The type of the rollout update.
4141
+ # Corresponds to the JSON property `rolloutUpdateType`
4142
+ # @return [String]
4143
+ attr_accessor :rollout_update_type
4144
+
4145
+ # ID of the target.
4146
+ # Corresponds to the JSON property `targetId`
4147
+ # @return [String]
4148
+ attr_accessor :target_id
4149
+
4150
+ # Type of this notification, e.g. for a rollout update event.
4151
+ # Corresponds to the JSON property `type`
4152
+ # @return [String]
4153
+ attr_accessor :type
4154
+
4155
+ def initialize(**args)
4156
+ update!(**args)
4157
+ end
4158
+
4159
+ # Update properties of this object
4160
+ def update!(**args)
4161
+ @message = args[:message] if args.key?(:message)
4162
+ @pipeline_uid = args[:pipeline_uid] if args.key?(:pipeline_uid)
4163
+ @release_uid = args[:release_uid] if args.key?(:release_uid)
4164
+ @rollout = args[:rollout] if args.key?(:rollout)
4165
+ @rollout_update_type = args[:rollout_update_type] if args.key?(:rollout_update_type)
4166
+ @target_id = args[:target_id] if args.key?(:target_id)
4167
+ @type = args[:type] if args.key?(:type)
4168
+ end
4169
+ end
4170
+
3183
4171
  # RuntimeConfig contains the runtime specific configurations for a deployment
3184
4172
  # strategy.
3185
4173
  class RuntimeConfig
@@ -3703,6 +4691,36 @@ module Google
3703
4691
  end
3704
4692
  end
3705
4693
 
4694
+ # Contains criteria for selecting Targets. Attributes provided must match the
4695
+ # target resource in order for policy restrictions to apply. E.g. if id "prod"
4696
+ # and labels "foo: bar" are given the target resource must match both that id
4697
+ # and have that label in order to be selected.
4698
+ class TargetAttribute
4699
+ include Google::Apis::Core::Hashable
4700
+
4701
+ # ID of the `Target`. The value of this field could be one of the following: *
4702
+ # The last segment of a target name. It only needs the ID to determine which
4703
+ # target is being referred to * "*", all targets in a location.
4704
+ # Corresponds to the JSON property `id`
4705
+ # @return [String]
4706
+ attr_accessor :id
4707
+
4708
+ # Target labels.
4709
+ # Corresponds to the JSON property `labels`
4710
+ # @return [Hash<String,String>]
4711
+ attr_accessor :labels
4712
+
4713
+ def initialize(**args)
4714
+ update!(**args)
4715
+ end
4716
+
4717
+ # Update properties of this object
4718
+ def update!(**args)
4719
+ @id = args[:id] if args.key?(:id)
4720
+ @labels = args[:labels] if args.key?(:labels)
4721
+ end
4722
+ end
4723
+
3706
4724
  # Payload proto for "clouddeploy.googleapis.com/target_notification" Platform
3707
4725
  # Log event that describes the failure to send target status change Pub/Sub
3708
4726
  # notification.