google-cloud-run-v2 0.1.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 (50) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +149 -0
  4. data/LICENSE.md +201 -0
  5. data/README.md +139 -0
  6. data/lib/google/cloud/run/v2/condition_pb.rb +111 -0
  7. data/lib/google/cloud/run/v2/k8s.min_pb.rb +88 -0
  8. data/lib/google/cloud/run/v2/revision_pb.rb +81 -0
  9. data/lib/google/cloud/run/v2/revision_services_pb.rb +49 -0
  10. data/lib/google/cloud/run/v2/revision_template_pb.rb +39 -0
  11. data/lib/google/cloud/run/v2/revisions/client.rb +619 -0
  12. data/lib/google/cloud/run/v2/revisions/credentials.rb +47 -0
  13. data/lib/google/cloud/run/v2/revisions/operations.rb +767 -0
  14. data/lib/google/cloud/run/v2/revisions/paths.rb +73 -0
  15. data/lib/google/cloud/run/v2/revisions.rb +50 -0
  16. data/lib/google/cloud/run/v2/service_pb.rb +100 -0
  17. data/lib/google/cloud/run/v2/service_services_pb.rb +65 -0
  18. data/lib/google/cloud/run/v2/services/client.rb +1154 -0
  19. data/lib/google/cloud/run/v2/services/credentials.rb +47 -0
  20. data/lib/google/cloud/run/v2/services/operations.rb +767 -0
  21. data/lib/google/cloud/run/v2/services/paths.rb +166 -0
  22. data/lib/google/cloud/run/v2/services.rb +50 -0
  23. data/lib/google/cloud/run/v2/traffic_target_pb.rb +41 -0
  24. data/lib/google/cloud/run/v2/vendor_settings_pb.rb +56 -0
  25. data/lib/google/cloud/run/v2/version.rb +28 -0
  26. data/lib/google/cloud/run/v2.rb +41 -0
  27. data/lib/google-cloud-run-v2.rb +21 -0
  28. data/proto_docs/README.md +4 -0
  29. data/proto_docs/google/api/field_behavior.rb +71 -0
  30. data/proto_docs/google/api/launch_stage.rb +71 -0
  31. data/proto_docs/google/api/resource.rb +222 -0
  32. data/proto_docs/google/cloud/run/v2/condition.rb +260 -0
  33. data/proto_docs/google/cloud/run/v2/k8s.min.rb +290 -0
  34. data/proto_docs/google/cloud/run/v2/revision.rb +225 -0
  35. data/proto_docs/google/cloud/run/v2/revision_template.rb +98 -0
  36. data/proto_docs/google/cloud/run/v2/service.rb +307 -0
  37. data/proto_docs/google/cloud/run/v2/traffic_target.rb +81 -0
  38. data/proto_docs/google/cloud/run/v2/vendor_settings.rb +109 -0
  39. data/proto_docs/google/iam/v1/iam_policy.rb +87 -0
  40. data/proto_docs/google/iam/v1/options.rb +50 -0
  41. data/proto_docs/google/iam/v1/policy.rb +418 -0
  42. data/proto_docs/google/longrunning/operations.rb +164 -0
  43. data/proto_docs/google/protobuf/any.rb +141 -0
  44. data/proto_docs/google/protobuf/duration.rb +98 -0
  45. data/proto_docs/google/protobuf/empty.rb +36 -0
  46. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  47. data/proto_docs/google/protobuf/timestamp.rb +129 -0
  48. data/proto_docs/google/rpc/status.rb +46 -0
  49. data/proto_docs/google/type/expr.rb +75 -0
  50. metadata +253 -0
@@ -0,0 +1,222 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2022 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 Api
22
+ # A simple descriptor of a resource type.
23
+ #
24
+ # ResourceDescriptor annotates a resource message (either by means of a
25
+ # protobuf annotation or use in the service config), and associates the
26
+ # resource's schema, the resource type, and the pattern of the resource name.
27
+ #
28
+ # Example:
29
+ #
30
+ # message Topic {
31
+ # // Indicates this message defines a resource schema.
32
+ # // Declares the resource type in the format of {service}/{kind}.
33
+ # // For Kubernetes resources, the format is {api group}/{kind}.
34
+ # option (google.api.resource) = {
35
+ # type: "pubsub.googleapis.com/Topic"
36
+ # pattern: "projects/{project}/topics/{topic}"
37
+ # };
38
+ # }
39
+ #
40
+ # The ResourceDescriptor Yaml config will look like:
41
+ #
42
+ # resources:
43
+ # - type: "pubsub.googleapis.com/Topic"
44
+ # pattern: "projects/{project}/topics/{topic}"
45
+ #
46
+ # Sometimes, resources have multiple patterns, typically because they can
47
+ # live under multiple parents.
48
+ #
49
+ # Example:
50
+ #
51
+ # message LogEntry {
52
+ # option (google.api.resource) = {
53
+ # type: "logging.googleapis.com/LogEntry"
54
+ # pattern: "projects/{project}/logs/{log}"
55
+ # pattern: "folders/{folder}/logs/{log}"
56
+ # pattern: "organizations/{organization}/logs/{log}"
57
+ # pattern: "billingAccounts/{billing_account}/logs/{log}"
58
+ # };
59
+ # }
60
+ #
61
+ # The ResourceDescriptor Yaml config will look like:
62
+ #
63
+ # resources:
64
+ # - type: 'logging.googleapis.com/LogEntry'
65
+ # pattern: "projects/{project}/logs/{log}"
66
+ # pattern: "folders/{folder}/logs/{log}"
67
+ # pattern: "organizations/{organization}/logs/{log}"
68
+ # pattern: "billingAccounts/{billing_account}/logs/{log}"
69
+ # @!attribute [rw] type
70
+ # @return [::String]
71
+ # The resource type. It must be in the format of
72
+ # \\{service_name}/\\{resource_type_kind}. The `resource_type_kind` must be
73
+ # singular and must not include version numbers.
74
+ #
75
+ # Example: `storage.googleapis.com/Bucket`
76
+ #
77
+ # The value of the resource_type_kind must follow the regular expression
78
+ # /[A-Za-z][a-zA-Z0-9]+/. It should start with an upper case character and
79
+ # should use PascalCase (UpperCamelCase). The maximum number of
80
+ # characters allowed for the `resource_type_kind` is 100.
81
+ # @!attribute [rw] pattern
82
+ # @return [::Array<::String>]
83
+ # Optional. The relative resource name pattern associated with this resource
84
+ # type. The DNS prefix of the full resource name shouldn't be specified here.
85
+ #
86
+ # The path pattern must follow the syntax, which aligns with HTTP binding
87
+ # syntax:
88
+ #
89
+ # Template = Segment { "/" Segment } ;
90
+ # Segment = LITERAL | Variable ;
91
+ # Variable = "{" LITERAL "}" ;
92
+ #
93
+ # Examples:
94
+ #
95
+ # - "projects/\\{project}/topics/\\{topic}"
96
+ # - "projects/\\{project}/knowledgeBases/\\{knowledge_base}"
97
+ #
98
+ # The components in braces correspond to the IDs for each resource in the
99
+ # hierarchy. It is expected that, if multiple patterns are provided,
100
+ # the same component name (e.g. "project") refers to IDs of the same
101
+ # type of resource.
102
+ # @!attribute [rw] name_field
103
+ # @return [::String]
104
+ # Optional. The field on the resource that designates the resource name
105
+ # field. If omitted, this is assumed to be "name".
106
+ # @!attribute [rw] history
107
+ # @return [::Google::Api::ResourceDescriptor::History]
108
+ # Optional. The historical or future-looking state of the resource pattern.
109
+ #
110
+ # Example:
111
+ #
112
+ # // The InspectTemplate message originally only supported resource
113
+ # // names with organization, and project was added later.
114
+ # message InspectTemplate {
115
+ # option (google.api.resource) = {
116
+ # type: "dlp.googleapis.com/InspectTemplate"
117
+ # pattern:
118
+ # "organizations/{organization}/inspectTemplates/{inspect_template}"
119
+ # pattern: "projects/{project}/inspectTemplates/{inspect_template}"
120
+ # history: ORIGINALLY_SINGLE_PATTERN
121
+ # };
122
+ # }
123
+ # @!attribute [rw] plural
124
+ # @return [::String]
125
+ # The plural name used in the resource name and permission names, such as
126
+ # 'projects' for the resource name of 'projects/\\{project}' and the permission
127
+ # name of 'cloudresourcemanager.googleapis.com/projects.get'. It is the same
128
+ # concept of the `plural` field in k8s CRD spec
129
+ # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/
130
+ #
131
+ # Note: The plural form is required even for singleton resources. See
132
+ # https://aip.dev/156
133
+ # @!attribute [rw] singular
134
+ # @return [::String]
135
+ # The same concept of the `singular` field in k8s CRD spec
136
+ # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/
137
+ # Such as "project" for the `resourcemanager.googleapis.com/Project` type.
138
+ # @!attribute [rw] style
139
+ # @return [::Array<::Google::Api::ResourceDescriptor::Style>]
140
+ # Style flag(s) for this resource.
141
+ # These indicate that a resource is expected to conform to a given
142
+ # style. See the specific style flags for additional information.
143
+ class ResourceDescriptor
144
+ include ::Google::Protobuf::MessageExts
145
+ extend ::Google::Protobuf::MessageExts::ClassMethods
146
+
147
+ # A description of the historical or future-looking state of the
148
+ # resource pattern.
149
+ module History
150
+ # The "unset" value.
151
+ HISTORY_UNSPECIFIED = 0
152
+
153
+ # The resource originally had one pattern and launched as such, and
154
+ # additional patterns were added later.
155
+ ORIGINALLY_SINGLE_PATTERN = 1
156
+
157
+ # The resource has one pattern, but the API owner expects to add more
158
+ # later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents
159
+ # that from being necessary once there are multiple patterns.)
160
+ FUTURE_MULTI_PATTERN = 2
161
+ end
162
+
163
+ # A flag representing a specific style that a resource claims to conform to.
164
+ module Style
165
+ # The unspecified value. Do not use.
166
+ STYLE_UNSPECIFIED = 0
167
+
168
+ # This resource is intended to be "declarative-friendly".
169
+ #
170
+ # Declarative-friendly resources must be more strictly consistent, and
171
+ # setting this to true communicates to tools that this resource should
172
+ # adhere to declarative-friendly expectations.
173
+ #
174
+ # Note: This is used by the API linter (linter.aip.dev) to enable
175
+ # additional checks.
176
+ DECLARATIVE_FRIENDLY = 1
177
+ end
178
+ end
179
+
180
+ # Defines a proto annotation that describes a string field that refers to
181
+ # an API resource.
182
+ # @!attribute [rw] type
183
+ # @return [::String]
184
+ # The resource type that the annotated field references.
185
+ #
186
+ # Example:
187
+ #
188
+ # message Subscription {
189
+ # string topic = 2 [(google.api.resource_reference) = {
190
+ # type: "pubsub.googleapis.com/Topic"
191
+ # }];
192
+ # }
193
+ #
194
+ # Occasionally, a field may reference an arbitrary resource. In this case,
195
+ # APIs use the special value * in their resource reference.
196
+ #
197
+ # Example:
198
+ #
199
+ # message GetIamPolicyRequest {
200
+ # string resource = 2 [(google.api.resource_reference) = {
201
+ # type: "*"
202
+ # }];
203
+ # }
204
+ # @!attribute [rw] child_type
205
+ # @return [::String]
206
+ # The resource type of a child collection that the annotated field
207
+ # references. This is useful for annotating the `parent` field that
208
+ # doesn't have a fixed resource type.
209
+ #
210
+ # Example:
211
+ #
212
+ # message ListLogEntriesRequest {
213
+ # string parent = 1 [(google.api.resource_reference) = {
214
+ # child_type: "logging.googleapis.com/LogEntry"
215
+ # };
216
+ # }
217
+ class ResourceReference
218
+ include ::Google::Protobuf::MessageExts
219
+ extend ::Google::Protobuf::MessageExts::ClassMethods
220
+ end
221
+ end
222
+ end
@@ -0,0 +1,260 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2022 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 Run
23
+ module V2
24
+ # Defines a status condition for a resource.
25
+ # @!attribute [rw] type
26
+ # @return [::String]
27
+ # type is used to communicate the status of the reconciliation process.
28
+ # See also:
29
+ # https://github.com/knative/serving/blob/main/docs/spec/errors.md#error-conditions-and-reporting
30
+ # Types common to all resources include:
31
+ # * "Ready": True when the Resource is ready.
32
+ # @!attribute [rw] state
33
+ # @return [::Google::Cloud::Run::V2::Condition::State]
34
+ # State of the condition.
35
+ # @!attribute [rw] message
36
+ # @return [::String]
37
+ # Human readable message indicating details about the current status.
38
+ # @!attribute [rw] last_transition_time
39
+ # @return [::Google::Protobuf::Timestamp]
40
+ # Last time the condition transitioned from one status to another.
41
+ # @!attribute [rw] severity
42
+ # @return [::Google::Cloud::Run::V2::Condition::Severity]
43
+ # How to interpret failures of this condition, one of Error, Warning, Info
44
+ # @!attribute [rw] reason
45
+ # @return [::Google::Cloud::Run::V2::Condition::CommonReason]
46
+ # A common (service-level) reason for this condition.
47
+ # @!attribute [rw] internal_reason
48
+ # @return [::Google::Cloud::Run::V2::Condition::InternalReason]
49
+ # A reason for the internal condition.
50
+ # @!attribute [rw] domain_mapping_reason
51
+ # @return [::Google::Cloud::Run::V2::Condition::DomainMappingReason]
52
+ # A reason for the domain mapping condition.
53
+ # @!attribute [rw] revision_reason
54
+ # @return [::Google::Cloud::Run::V2::Condition::RevisionReason]
55
+ # A reason for the revision condition.
56
+ # @!attribute [rw] execution_reason
57
+ # @return [::Google::Cloud::Run::V2::Condition::ExecutionReason]
58
+ # A reason for the execution condition.
59
+ class Condition
60
+ include ::Google::Protobuf::MessageExts
61
+ extend ::Google::Protobuf::MessageExts::ClassMethods
62
+
63
+ # Represents the possible Condition states.
64
+ module State
65
+ # The default value. This value is used if the state is omitted.
66
+ STATE_UNSPECIFIED = 0
67
+
68
+ # Transient state: Reconciliation has not started yet.
69
+ CONDITION_PENDING = 1
70
+
71
+ # Transient state: reconciliation is still in progress.
72
+ CONDITION_RECONCILING = 2
73
+
74
+ # Terminal state: Reconciliation did not succeed.
75
+ CONDITION_FAILED = 3
76
+
77
+ # Terminal state: Reconciliation completed successfully.
78
+ CONDITION_SUCCEEDED = 4
79
+ end
80
+
81
+ # Represents the severity of the condition failures.
82
+ module Severity
83
+ # Unspecified severity
84
+ SEVERITY_UNSPECIFIED = 0
85
+
86
+ # Error severity.
87
+ ERROR = 1
88
+
89
+ # Warning severity.
90
+ WARNING = 2
91
+
92
+ # Info severity.
93
+ INFO = 3
94
+ end
95
+
96
+ # Reasons common to all types of conditions.
97
+ module CommonReason
98
+ # Default value.
99
+ COMMON_REASON_UNDEFINED = 0
100
+
101
+ # Reason unknown. Further details will be in message.
102
+ UNKNOWN = 1
103
+
104
+ # The internal route is missing.
105
+ ROUTE_MISSING = 2
106
+
107
+ # Revision creation process failed.
108
+ REVISION_FAILED = 3
109
+
110
+ # Timed out waiting for completion.
111
+ PROGRESS_DEADLINE_EXCEEDED = 4
112
+
113
+ # There was a build error.
114
+ BUILD_STEP_FAILED = 5
115
+
116
+ # The container image path is incorrect.
117
+ CONTAINER_MISSING = 6
118
+
119
+ # Insufficient permissions on the container image.
120
+ CONTAINER_PERMISSION_DENIED = 7
121
+
122
+ # Container image is not authorized by policy.
123
+ CONTAINER_IMAGE_UNAUTHORIZED = 8
124
+
125
+ # Container image policy authorization check failed.
126
+ CONTAINER_IMAGE_AUTHORIZATION_CHECK_FAILED = 9
127
+
128
+ # Insufficient permissions on encryption key.
129
+ ENCRYPTION_KEY_PERMISSION_DENIED = 10
130
+
131
+ # Permission check on encryption key failed.
132
+ ENCRYPTION_KEY_CHECK_FAILED = 11
133
+
134
+ # At least one Access check on secrets failed.
135
+ SECRETS_ACCESS_CHECK_FAILED = 12
136
+
137
+ # Waiting for operation to complete.
138
+ WAITING_FOR_OPERATION = 13
139
+
140
+ # System will retry immediately.
141
+ IMMEDIATE_RETRY = 14
142
+
143
+ # System will retry later; current attempt failed.
144
+ POSTPONED_RETRY = 15
145
+ end
146
+
147
+ # Reasons applicable to internal resources not exposed to users. These will
148
+ # surface in Service.conditions, and could be useful for further diagnosis.
149
+ module InternalReason
150
+ # Default value.
151
+ INTERNAL_REASON_UNDEFINED = 0
152
+
153
+ # The revision name provided conflicts with an existing one.
154
+ CONFLICTING_REVISION_NAME = 1
155
+
156
+ # Revision is missing; this is usually a transient reason.
157
+ REVISION_MISSING = 2
158
+
159
+ # Internal configuration is missing; this is usually a transient reason.
160
+ CONFIGURATION_MISSING = 3
161
+
162
+ # Assigning traffic; this is a transient reason.
163
+ ASSIGNING_TRAFFIC = 4
164
+
165
+ # Updating ingress traffic settings; this is a transient reason.
166
+ UPDATING_INGRESS_TRAFFIC_ALLOWED = 5
167
+
168
+ # The revision can't be created because it violates an org policy setting.
169
+ REVISION_ORG_POLICY_VIOLATION = 6
170
+
171
+ # Enabling GCFv2 URI support; this is a transient reason.
172
+ ENABLING_GCFV2_URI_SUPPORT = 7
173
+ end
174
+
175
+ # Reasons specific to DomainMapping resource.
176
+ module DomainMappingReason
177
+ # Default value.
178
+ DOMAIN_MAPPING_REASON_UNDEFINED = 0
179
+
180
+ # Internal route is not yet ready.
181
+ ROUTE_NOT_READY = 1
182
+
183
+ # Insufficient permissions.
184
+ PERMISSION_DENIED = 2
185
+
186
+ # Certificate already exists.
187
+ CERTIFICATE_ALREADY_EXISTS = 3
188
+
189
+ # Mapping already exists.
190
+ MAPPING_ALREADY_EXISTS = 4
191
+
192
+ # Certificate issuance pending.
193
+ CERTIFICATE_PENDING = 5
194
+
195
+ # Certificate issuance failed.
196
+ CERTIFICATE_FAILED = 6
197
+ end
198
+
199
+ # Reasons specific to Revision resource.
200
+ module RevisionReason
201
+ # Default value.
202
+ REVISION_REASON_UNDEFINED = 0
203
+
204
+ # Revision in Pending state.
205
+ PENDING = 1
206
+
207
+ # Revision is in Reserve state.
208
+ RESERVE = 2
209
+
210
+ # Revision is Retired.
211
+ RETIRED = 3
212
+
213
+ # Revision is being retired.
214
+ RETIRING = 4
215
+
216
+ # Revision is being recreated.
217
+ RECREATING = 5
218
+
219
+ # There was a health check error.
220
+ HEALTH_CHECK_CONTAINER_ERROR = 6
221
+
222
+ # Health check failed due to user error from customized path of the
223
+ # container. System will retry.
224
+ CUSTOMIZED_PATH_RESPONSE_PENDING = 7
225
+
226
+ # A revision with min_instance_count > 0 was created and is reserved, but
227
+ # it was not configured to serve traffic, so it's not live. This can also
228
+ # happen momentarily during traffic migration.
229
+ MIN_INSTANCES_NOT_PROVISIONED = 8
230
+
231
+ # The maximum allowed number of active revisions has been reached.
232
+ ACTIVE_REVISION_LIMIT_REACHED = 9
233
+
234
+ # There was no deployment defined.
235
+ # This value is no longer used, but Services created in older versions of
236
+ # the API might contain this value.
237
+ NO_DEPLOYMENT = 10
238
+
239
+ # A revision's container has no port specified since the revision is of a
240
+ # manually scaled service with 0 instance count
241
+ HEALTH_CHECK_SKIPPED = 11
242
+ end
243
+
244
+ # Reasons specific to Execution resource.
245
+ module ExecutionReason
246
+ # Default value.
247
+ EXECUTION_REASON_UNDEFINED = 0
248
+
249
+ # Internal system error getting execution status. System will retry.
250
+ JOB_STATUS_SERVICE_POLLING_ERROR = 1
251
+
252
+ # A task reached its retry limit and the last attempt failed due to the
253
+ # user container exiting with a non-zero exit code.
254
+ NON_ZERO_EXIT_CODE = 2
255
+ end
256
+ end
257
+ end
258
+ end
259
+ end
260
+ end