-
Notifications
You must be signed in to change notification settings - Fork 96
/
metadata.yaml
341 lines (340 loc) · 12.1 KB
/
metadata.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
# Copyright 2024 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
apiVersion: blueprints.cloud.google.com/v1alpha1
kind: BlueprintMetadata
metadata:
name: terraform-google-cloud-run
annotations:
config.kubernetes.io/local-config: "true"
spec:
info:
title: Terraform Cloud Run Module
source:
repo: https://github.com/GoogleCloudPlatform/terraform-google-cloud-run.git
sourceType: git
version: 0.13.0
actuationTool:
flavor: Terraform
version: ">= 1.3"
description: {}
content:
subBlueprints:
- name: job-exec
location: modules/job-exec
- name: secure-cloud-run
location: modules/secure-cloud-run
- name: secure-cloud-run-core
location: modules/secure-cloud-run-core
- name: secure-cloud-run-security
location: modules/secure-cloud-run-security
- name: secure-serverless-harness
location: modules/secure-serverless-harness
- name: secure-serverless-net
location: modules/secure-serverless-net
- name: service-project-factory
location: modules/service-project-factory
- name: v2
location: modules/v2
examples:
- name: cloud_run_vpc_connector
location: examples/cloud_run_vpc_connector
- name: secure_cloud_run
location: examples/secure_cloud_run
- name: secure_cloud_run_standalone
location: examples/secure_cloud_run_standalone
- name: simple_cloud_run
location: examples/simple_cloud_run
- name: simple_cloud_run_with_cmek
location: examples/simple_cloud_run_with_cmek
- name: simple_job_exec
location: examples/simple_job_exec
- name: v2
location: examples/v2
interfaces:
variables:
- name: project_id
description: The project ID to deploy to
varType: string
required: true
- name: service_name
description: The name of the Cloud Run service to create
varType: string
required: true
- name: location
description: Cloud Run service deployment location
varType: string
required: true
- name: image
description: GCR hosted image URL to deploy
varType: string
required: true
- name: generate_revision_name
description: Option to enable revision name generation
varType: bool
defaultValue: true
- name: traffic_split
description: Managing traffic routing to the service
varType: |-
list(object({
latest_revision = bool
percent = number
revision_name = string
tag = string
}))
defaultValue:
- latest_revision: true
percent: 100
revision_name: v1-0-0
tag: null
- name: service_labels
description: A set of key/value label pairs to assign to the service
varType: map(string)
defaultValue: {}
- name: service_annotations
description: Annotations to the service. Acceptable values all, internal, internal-and-cloud-load-balancing
varType: map(string)
defaultValue:
run.googleapis.com/ingress: all
- name: template_labels
description: A set of key/value label pairs to assign to the container metadata
varType: map(string)
defaultValue: {}
- name: template_annotations
description: Annotations to the container metadata including VPC Connector and SQL. See [more details](https://cloud.google.com/run/docs/reference/rpc/google.cloud.run.v1#revisiontemplate)
varType: map(string)
defaultValue:
autoscaling.knative.dev/maxScale: 2
autoscaling.knative.dev/minScale: 1
generated-by: terraform
run.googleapis.com/client-name: terraform
- name: encryption_key
description: CMEK encryption key self-link expected in the format projects/PROJECT/locations/LOCATION/keyRings/KEY-RING/cryptoKeys/CRYPTO-KEY.
varType: string
- name: container_concurrency
description: Concurrent request limits to the service
varType: number
- name: timeout_seconds
description: Timeout for each request
varType: number
defaultValue: 120
- name: service_account_email
description: Service Account email needed for the service
varType: string
defaultValue: ""
- name: volumes
description: "[Beta] Volumes needed for environment variables (when using secret)"
varType: |-
list(object({
name = string
secret = set(object({
secret_name = string
items = map(string)
}))
}))
defaultValue: []
- name: limits
description: Resource limits to the container
varType: map(string)
- name: requests
description: Resource requests to the container
varType: map(string)
defaultValue: {}
- name: ports
description: Port which the container listens to (http1 or h2c)
varType: |-
object({
name = string
port = number
})
defaultValue:
name: http1
port: 8080
- name: argument
description: Arguments passed to the ENTRYPOINT command, include these only if image entrypoint needs arguments
varType: list(string)
defaultValue: []
- name: container_command
description: Leave blank to use the ENTRYPOINT command defined in the container image, include these only if image entrypoint should be overwritten
varType: list(string)
defaultValue: []
- name: startup_probe
description: |
Startup probe of application within the container.
All other probes are disabled if a startup probe is provided, until it succeeds.
Container will not be added to service endpoints if the probe fails.
More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
varType: |-
object({
failure_threshold = optional(number, null)
initial_delay_seconds = optional(number, null)
timeout_seconds = optional(number, null)
period_seconds = optional(number, null)
http_get = optional(object({
path = optional(string)
http_headers = optional(list(object({
name = string
value = string
})), null)
}), null)
tcp_socket = optional(object({
port = optional(number)
}), null)
grpc = optional(object({
port = optional(number)
service = optional(string)
}), null)
})
- name: liveness_probe
description: |
Periodic probe of container liveness. Container will be restarted if the probe fails.
More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes
varType: |-
object({
failure_threshold = optional(number, null)
initial_delay_seconds = optional(number, null)
timeout_seconds = optional(number, null)
period_seconds = optional(number, null)
http_get = optional(object({
path = optional(string)
http_headers = optional(list(object({
name = string
value = string
})), null)
}), null)
grpc = optional(object({
port = optional(number)
service = optional(string)
}), null)
})
- name: env_vars
description: Environment variables (cleartext)
varType: |-
list(object({
value = string
name = string
}))
defaultValue: []
- name: env_secret_vars
description: "[Beta] Environment variables (Secret Manager)"
varType: |-
list(object({
name = string
value_from = set(object({
secret_key_ref = map(string)
}))
}))
defaultValue: []
- name: volume_mounts
description: "[Beta] Volume Mounts to be attached to the container (when using secret)"
varType: |-
list(object({
mount_path = string
name = string
}))
defaultValue: []
- name: verified_domain_name
description: List of Custom Domain Name
varType: list(string)
defaultValue: []
- name: force_override
description: Option to force override existing mapping
varType: bool
defaultValue: false
- name: certificate_mode
description: The mode of the certificate (NONE or AUTOMATIC)
varType: string
defaultValue: NONE
- name: domain_map_labels
description: A set of key/value label pairs to assign to the Domain mapping
varType: map(string)
defaultValue: {}
- name: domain_map_annotations
description: Annotations to the domain map
varType: map(string)
defaultValue: {}
- name: members
description: Users/SAs to be given invoker access to the service
varType: list(string)
defaultValue: []
outputs:
- name: apphub_service_uri
description: Service URI in CAIS style to be used by Apphub.
type:
- object
- service_id: string
service_uri: string
- name: domain_map_id
description: Unique Identifier for the created domain map
type:
- tuple
- []
- name: domain_map_status
description: Status of Domain mapping
type:
- tuple
- []
- name: location
description: Location in which the Cloud Run service was created
type: string
- name: project_id
description: Google Cloud project in which the service was created
type: string
- name: revision
description: Deployed revision for the service
type: string
- name: service_id
description: Unique Identifier for the created service
type: string
- name: service_name
description: Name of the created service
type: string
- name: service_status
description: Status of the created service
type: string
- name: service_url
description: The URL on which the deployed service is available
type: string
- name: verified_domain_name
description: List of Custom Domain Name
type:
- tuple
- []
requirements:
roles:
- level: Project
roles:
- roles/accesscontextmanager.policyAdmin
- roles/orgpolicy.policyAdmin
- level: Project
roles:
- roles/owner
- level: Project
roles:
- roles/resourcemanager.folderAdmin
- roles/resourcemanager.projectCreator
- roles/resourcemanager.projectDeleter
services:
- cloudresourcemanager.googleapis.com
- storage-api.googleapis.com
- serviceusage.googleapis.com
- run.googleapis.com
- cloudkms.googleapis.com
- iam.googleapis.com
- accesscontextmanager.googleapis.com
- cloudbilling.googleapis.com
providerVersions:
- source: hashicorp/google
version: < 7
- source: hashicorp/google-beta
version: < 7