-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.yaml
executable file
·426 lines (366 loc) · 12.7 KB
/
schema.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
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
title: "Use OCI DevOps CICD with Functions"
description: "Create Function and DevOps Deploy service to manage your Functions deployments."
schemaVersion: 1.1.0
version: "20190304"
locale: "en"
##################
#Variable Groups
##################
variableGroups:
- title: General Configuration
visible: false
variables:
- tenancy_ocid
- region
- user_ocid
- fingerprint
- private_key_path
- network_cidrs
- app_version
- app_version2
- deploy_pipeline_deploy_pipeline_parameters_items_default_value
- deploy_pipeline_deploy_pipeline_parameters_items_description
- deploy_pipeline_deploy_pipeline_parameters_items_name
- build_pipeline_stage_build_pipeline_stage_predecessor_collection_items_id
- build_pipeline_stage_build_pipeline_stage_type
- build_pipeline_stage_wait_criteria_wait_duration
- build_pipeline_stage_wait_criteria_wait_type
- build_pipeline_stage_build_source_collection_items_branch
- build_pipeline_stage_build_source_collection_items_connection_type
- build_pipeline_stage_deliver_artifact_stage_type
- deploy_artifact_argument_substitution_mode
- deploy_artifact_deploy_artifact_source_deploy_artifact_source_type
- deploy_artifact_deploy_artifact_type
- build_pipeline_stage_deploy_stage_type
- build_pipeline_stage_is_pass_all_parameters_enabled
- trigger_actions_type
- trigger_trigger_source
- trigger_trigger_input_event_type
- trigger_state
- trigger_source_repo_branch
- trigger_action_to_invoke
- deploy_stage_deploy_stage_type
- compartment_ocid
- environment_type
- release
- title: Required Configuration
visible: true
variables:
- app_name
- oci_user_name
- oci_user_authtoken
- execute_deployment
- show_advanced
- title: Network Configuration
visible: true
variables:
- VCN-CIDR
- fnsubnet-CIDR
- title: DevOps Project
visible: true
variables:
- compartment_id
- project_logging_config_retention_period_in_days
- title: Git and OCI DevOps Repositories
visible: true
variables:
- repository_name
- repository_repository_type
- repository_default_branch
- repository_description
- git_repo
- git_repo_name
- title: DevOps Build Pipeline
visible: true
variables:
- deploy_stage_display_name
- build_pipeline_description
- build_pipeline_build_stage_description
- build_pipeline_display_name
- build_pipeline_stage_display_name
- build_pipeline_stage_build_spec_file
- build_pipeline_stage_image
- build_pipeline_stage_stage_execution_timeout_in_seconds
- build_pipeline_stage_build_source_collection_items_name
- build_pipeline_stage_deliver_artifact_collection_items_artifact_name_default
- build_pipeline_stage_deliver_artifact_collection_items_artifact_name_custom
- title: DevOps Artifacts
visible:
and:
- show_advanced
variables:
- container_repository_is_public
- deliver_artifact_stage_display_name
- title: DevOps Deploy Pipelines
visible:
and:
- show_advanced
variables:
- deploy_pipeline_description
- deploy_stage_namespace
- title: Policy Settings
description: Policy setting for the stack deployment
visible: true
variables:
- create_dynamic_group_for_devops_pipln_in_compartment
- create_dynamic_group_for_nodes_in_compartment
- existent_dynamic_group_for_nodes_in_compartment
- create_compartment_policies
- create_tenancy_policies
#######################
#Variable Definitions
#######################
variables:
compartment_id:
type: oci:identity:compartment:id
title: "Compartment"
description: "The compartment in which to create resources"
required: true
oci_user_name:
type: string
required: true
visibile: true
title: "OCI username"
description: "For a federated user (single sign-on with an identity provider), enter the username in the following format: TenancyName/Federation/UserName. For example, if you use OCI's identity provider, your login would be, Acme/oracleidentitycloudservice/alice.jones@acme.com. If you are using OCI's direct sign-in, enter the username in the following format: TenancyName/YourUserName. For example, Acme/alice_jones. Your password is the auth token you created previously."
oci_user_authtoken:
type: password
required: true
visibile: true
title: "OCI user password"
description: "You can get the auth token from your Profile menu -> click User Settings -> On left side click *Auth Tokens -> Generate Token"
app_name:
type: string
title: "HelloWorldFn"
required: true
show_advanced:
type: boolean
title: "Show advanced options?"
description: "Shows advanced options, allowing enable customer-managed encryption keys, select your ssh key, select/unselect cluster utilities, do not create policies, and other advanced options"
visible: true
default: false
execute_deployment:
type: boolean
title: "Execute deployment in DevOps Pipeline?"
description: "Choose if you want to start deployment in DevOps Pipeline as a part of this Terraform automation."
visible: true
default: false
################
# Repositories
###############
repository_name:
type: string
default: "python-function-helloworld"
required: false
title: "OCI DevOps Repository Name."
description: "OCI DevOps Repository Name, which will be used for git clone of your GitHub repo will be stored for bulid process"
repository_repository_type:
type: enum
enum:
- "HOSTED"
title: "OCI DevOps Repository Type"
description: "OCI DevOps Repository Type (currently HOSTED is the only accepted value)."
default: "HOSTED"
repository_default_branch:
type: string
default: "main"
required: false
title: "OCI DevOps Repository Default Branch."
description: "OCI DevOps Repository Default Branch."
repository_description:
type: string
default: "Sample code for OCI Function with python"
required: false
title: "OCI DevOps Repository description"
description: "OCI DevOps Repository description."
git_repo:
type: string
default: "https://github.com/RahulMR42/oci-sample-function-with-python"
required: false
title: "GitHub repository URL"
description: "GitHub repository URL with the source of the code to be build and deployed."
git_repo_name:
type: string
default: "oci-sample-function-with-python"
required: false
title: "GitHub repository name"
description: "GitHub repository name with the source of the code to be build and deployed."
###############
# DevOps Build
###############
deploy_stage_display_name:
type: string
default: "Invoke-Deployment"
required: false
title: "Deploy Stage Display Name"
description: "Deploy Stage Display Name in the Build Pipeline."
build_pipeline_description:
type: string
default: "Build pipeline for OCI Function with Python"
required: false
title: "Build Pipeline Description"
description: "Build Pipeline Description."
build_pipeline_build_stage_description:
type: string
default: "Build Stage for OCI Function with python"
required: false
title: "Build Stage of Build Pipeline - Description"
description: "Build Stage of Build Pipeline - Description."
build_pipeline_display_name:
type: string
default: "Function-Python-Buildpipeline"
required: false
title: "Build Pipeline Display Name"
description: "Build Pipeline Display Name."
build_pipeline_stage_display_name:
type: string
default: "function-python-build"
required: false
title: "Build Stage of Build Pipeline - Display Name"
description: "Build Stage of Build Pipeline - Display Name."
build_pipeline_stage_build_spec_file:
type: string
default: ""
required: false
title: "Build Stage of Build Pipeline - Spec File"
description: "Build Stage of Build Pipeline -Spec File."
build_pipeline_stage_image:
type: enum
enum:
- "OL7_X86_64_STANDARD_10"
title: "Build Stage of Build Pipeline - Image"
description: "Build Stage of Build Pipeline - Image (currently OL7_X86_64_STANDARD_10 is the only accepted value)."
default: "OL7_X86_64_STANDARD_10"
build_pipeline_stage_stage_execution_timeout_in_seconds:
type: number
title: "Build Stage of Build Pipeline - Stage Execution Timeout (in seconds)"
description: "Build Stage of Build Pipeline - Stage Execution Timeout (in seconds)."
minimum: 1
maximum: 120000
multipleOf: 1
default: 36000
build_pipeline_stage_build_source_collection_items_name:
type: string
default: "oci-sample-function-with-python"
required: false
title: "Build Stage of Build Source Collection Items Name"
description: "Build Stage of Build Source Collection Items Name."
build_pipeline_stage_deliver_artifact_collection_items_artifact_name_default:
type: string
default: "output_fn_default_image"
required: false
title: "Deliver Artifact Stage of Build - Collection Items Name Default"
description: "Deliver Artifact Stage of Build - Collection Items Name Default."
build_pipeline_stage_deliver_artifact_collection_items_artifact_name_custom:
type: string
default: "output_fn_custom_image"
required: false
title: "Deliver Artifact Stage of Build - Collection Items Name Custom"
description: "Deliver Artifact Stage of Build - Collection Items Name Custom."
##########
# Network
#########
VCN-CIDR:
type: string
required: false
default: "10.0.0.0/16"
pattern: "^(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9])\\/(3[0-2]|[1-2]?[0-9])$"
description: "VCN CIDR block where you want to create the App/Function resources."
fnsubnet-CIDR:
type: string
required: false
default: "10.0.1.0/24"
pattern: "^(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9]).(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9]?[0-9])\\/(3[0-2]|[1-2]?[0-9])$"
description: "Subnet CIDR block where you want to create the App/Function resources."
#############
# DevOps Project
#############
project_logging_config_retention_period_in_days:
type: number
title: "Project Logs retention period"
description: "Days to retain logs from the Project."
minimum: 1
maximum: 128
multipleOf: 1
default: 30
required: true
visible:
and:
- show_advanced
#############
# DevOps Artifacts
#############
container_repository_is_public:
type: boolean
title: "Is the container repository public?"
description: "Check if the container repository should be public."
visible: true
default: true
deliver_artifact_stage_display_name:
type: string
default: "Deliver-Artifact-Stage"
required: false
title: "Deliver Artifact Stage Display Name"
description: "Deliver Artifact Stage Display Name."
##################
# Deploy Pipeline
##################
deploy_pipeline_description:
type: string
default: "Deploy-Function-Pipeline"
required: false
title: "Deploy Pipeline Description"
description: "Deploy Pipeline Description."
############
#Pipeline
############
create_dynamic_group_for_devops_pipln_in_compartment:
type: boolean
title: "Create a Dynamic Group for DevOps Pipelines"
description: "You need to be an administrator to do this. Alternatively you can have the administrator create Dynamic group for you."
default: true
deploy_stage_deploy_stage_type:
type: enum
enum:
- "DEPLOY_FUNCTION"
title: "Stage Type"
description: "DevOps Stage Type"
default: "DEPLOY_FUNCTION"
deploy_stage_namespace:
type: string
title: "Namespace to use"
description: "namespace to use for deployment."
default: "default"
create_dynamic_group_for_nodes_in_compartment:
type: boolean
title: "Create Dynamic Group for Worker Nodes in the Compartment"
required: true
visible:
and:
- show_advanced
existent_dynamic_group_for_nodes_in_compartment:
type: string
required: true
title: "Existent Dynamic Group"
visible:
and:
- and:
- show_advanced
- or:
- create_compartment_policies
- create_tenancy_policies
- not:
- create_dynamic_group_for_nodes_in_compartment
create_compartment_policies:
type: boolean
title: "Create Compartment Policies"
required: true
visible:
and:
- show_advanced
create_tenancy_policies:
type: boolean
title: "Create Tenancy Policies"
required: true
visible:
and:
- show_advanced