-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathplugin.yaml
747 lines (704 loc) · 26.9 KB
/
plugin.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
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
##################################################################################
# Cloudify Ansible Tower built in types and plugins definitions.
##################################################################################
plugins:
plugin:
executor: central_deployment_agent
source: https://github.com/cloudify-incubator/cloudify-ansible-tower-plugin/archive/1.0.0.zip
package_name: cloudify-ansible-tower-plugin
package_version: '1.0.1'
data_types:
cloudify.datatypes.ansible_tower.ConnectionConfig:
properties:
access_token:
description: >
User authentication token
type: string
required: false
endpoint:
description: >
The complete URL to use for the constructed
client. This should be without a trailing slash.
Example: https://tower.example.com
type: string
required: false
endpoint_verify:
type: boolean
default: true
required: false
cloudify.datatypes.ansible_tower.User.config:
properties:
username:
type: string
required: false
first_name:
type: string
default: ""
last_name:
type: string
default: ""
email:
type: string
default: ""
is_superuser:
type: boolean
default: false
is_system_auditor:
type: boolean
default: false
password:
type: string
default: ""
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Users/Users_users_create
default: {}
cloudify.datatypes.ansible_tower.Organization.config:
properties:
name:
description: >
Name of this organization. (string, required)
type: string
required: false
description:
description: >
Optional description of this organization. (string, default="")
type: string
default: ""
max_hosts:
description: >
Maximum number of hosts allowed to be managed by this organization. (integer, default=0)
type: integer
default: 0
custom_virtualenv:
description: >
Local absolute file path containing a custom Python virtualenv to use (string, default="")
type: string
default: ""
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Organizations/Organizations_organizations_create
default: {}
cloudify.datatypes.ansible_tower.Team.config:
properties:
name:
description: >
Name of this team. (string, required)
type: string
required: false
description:
description: >
Optional description of this team. (string, default="")
type: string
default: ""
organization:
description: >
Inherit permissions from organization roles. (id, required)
required: false
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Teams/Teams_teams_create
default: {}
cloudify.datatypes.ansible_tower.CredentialType.config:
properties:
name:
type: string
required: false
description:
type: string
default: ""
kind:
type: string
required: false
inputs:
default: {}
injectors:
default: {}
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Credential_Types/Credential_Types_credential_types_create
default: {}
cloudify.datatypes.ansible_tower.Credential.config:
properties:
name:
description: >
Name of this credential. (string, required)
type: string
required: false
description:
description: >
Optional description of this credential. (string, default="")
type: string
default: ""
organization:
description: >
Inherit permissions from organization roles. If provided on creation, do not give either user or team. (id, default=None)
required: false
credential_type:
description: >
Specify the type of credential you want to create. Refer to the Ansible Tower documentation for details on each type. (id, required)
required: false
inputs:
description: >
Enter inputs using either JSON or YAML syntax. Refer to the Ansible Tower documentation for example syntax. (json, default={})
default: {}
user:
description: >
Used to add user to owner role. If provided, do not give either team or organization. Only valid for creation. (id, default=None)
required: false
team:
description: >
used to add team to owner role. If provided, do not give either user or organization. Only valid for creation. (id, default=None)
required: false
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Credentials/Credentials_credentials_create
default: {}
cloudify.datatypes.ansible_tower.Project.config:
properties:
name:
required: false
description: Name of this project. (string, required)
description:
required: false
description: Optional description of this project. (string, default="")
default: ""
local_path:
required: false
description: Local path (relative to PROJECTS_ROOT) containing playbooks and related files for this project. (string, default="")
scm_type:
required: false
description: Specifies the source control system used to store the project. (choice)
scm_url:
required: false
description: The location where the project is stored. (string, default="")
scm_branch:
required: false
description: Specific branch, tag or commit to checkout. (string, default="")
scm_refspec:
required: false
description: For git projects, an additional refspec to fetch. (string, default="")
scm_clean:
required: false
description: Discard any local changes before syncing the project. (boolean, default=False)
default: false
scm_delete_on_update:
required: false
description: Delete the project before syncing. (boolean, default=False)
default: false
credential:
required: false
description: (id)
timeout:
required: false
description: The amount of time (in seconds) to run before the task is canceled. (integer, default=0)
default: 0
organization:
required: false
description: (id)
scm_update_on_launch:
required: false
description: Update the project when a job is launched that uses the project. (boolean, default=False)
default: false
scm_update_cache_timeout:
required: false
description: The number of seconds after the last project update ran that a new project update will be launched as a job dependency. (integer, default=0)
default: 0
allow_override:
required: false
description: Allow changing the SCM branch or revision in a job template that uses this project. (boolean, default=False)
default: false
custom_virtualenv:
required: false
description: Local absolute file path containing a custom Python virtualenv to use (string, default="")
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Projects/Projects_projects_create
default: {}
cloudify.datatypes.ansible_tower.JobTemplate.config:
properties:
name:
required: false
description: Name of this job template. (string, required)
description:
required: false
description: Optional description of this job template. (string, default="")
job_type:
required: false
description: ([run, check, scan], default="run")
default: run
inventory:
required: false
description: (id, default=``)
project:
required: false
description: (id, default=``)
playbook:
required: false
description: (string, default="")
scm_branch:
required: false
description: Branch to use in job run. Project default used if blank. Only allowed if project allow_override field is set to true. (string, default="")
forks:
required: false
description: (integer, default=0)
default: 0
limit:
required: false
description: (string, default="")
verbosity:
required: false
description: (0-5, default=0)
default: 0
extra_vars:
required: false
description: (json, default=``)
job_tags:
required: false
description: (string, default="")
force_handlers:
required: false
description: (boolean, default=False)
default: false
skip_tags:
required: false
description: (string, default="")
start_at_task:
required: false
description: (string, default="")
timeout:
required: false
description: The amount of time (in seconds) to run before the task is canceled. (integer, default=0)
default: 0
use_fact_cache:
required: false
description: If enabled, Tower will act as an Ansible Fact Cache Plugin; persisting facts at the end of a playbook run to the database and caching facts for use by Ansible. (boolean, default=False)
host_config_key:
required: false
description: (string, default="")
ask_scm_branch_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_diff_mode_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_variables_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_limit_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_tags_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_skip_tags_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_job_type_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_verbosity_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_inventory_on_launch:
required: false
description: (boolean, default=False)
default: false
ask_credential_on_launch:
required: false
description: (boolean, default=False)
default: false
survey_enabled:
required: false
description: (boolean, default=False)
default: false
become_enabled:
required: false
description: (boolean, default=False)
default: false
diff_mode:
required: false
description: If enabled, textual changes made to any templated files on the host are shown in the standard output (boolean, default=False)
default: false
allow_simultaneous:
required: false
description: (boolean, default=False)
default: false
custom_virtualenv:
required: false
description: Local absolute file path containing a custom Python virtualenv to use (string, default="")
job_slice_count:
required: false
description: The number of jobs to slice into at runtime. Will cause the Job Template to launch a workflow if value is greater than 1. (integer, default=1)
default: 1
webhook_service:
required: false
description: Service that webhook requests will be accepted from ([github, gitlab])
webhook_credential:
required: false
description: Personal Access Token for posting back the status to the service API (id, default="")
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Job_Templates/Job_Templates_job_templates_create
default: {}
cloudify.datatypes.ansible_tower.Job.config:
properties:
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Job_Templates/Job_Templates_job_templates_launch_create
default: {}
cloudify.datatypes.ansible_tower.Inventory.config:
properties:
name:
required: false
description: Name of this inventory. (string, required)
description:
required: false
description: Optional description of this inventory. (string, default="")
organization:
required: false
description: Organization containing this inventory. (id, required)
kind:
required: false
description: Kind of inventory being represented. (["", smart], default="")
host_filter:
required: false
description: Filter that will be applied to the hosts of this inventory. (string, default="")
variables:
required: false
description: Inventory variables in JSON or YAML format. (json, default=``)
insights_credential:
required: false
description: Credentials to be used by hosts belonging to this inventory when accessing Red Hat Insights API. (id, default=``)
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Inventories/Inventories_inventories_create
default: {}
cloudify.datatypes.ansible_tower.Host.config:
properties:
name:
required: false
description: Name of this host. (string, required)
description:
required: false
description: Optional description of this host. (string, default="")
enabled:
required: false
description: Is this host online and available for running jobs? (boolean, default=True)
instance_id:
required: false
description: The value used by the remote inventory source to uniquely identify the host (string, default="")
variables:
required: false
description: Host variables in JSON or YAML format. (json, default=``)
kwargs:
description: https://docs.ansible.com/ansible-tower/latest/html/towerapi/api_ref.html#/Inventories/Inventories_inventories_hosts_create
default: {}
dsl_definitions:
use_external_resource_desc: &use_external_resource_desc >
Indicate whether the resource exists or if Cloudify should create the resource,
true if you are bringing an existing resource, false if you want cloudify to create it.
resource_id_desc: &resource_id_desc >
The resource ID of the external resource, if
use_external_resource is true. Otherwise it is an empty string.
# Every operation uses these inputs, unless noted.
operation_inputs: &operation_inputs
runtime_properties:
description: >
This overrides any runtime property at runtime. This is a key-value
pair / dictionary that will be passed, as-is, to the runtime properties
of the running instance.
required: false
default: ~
force_operation:
description: >
Forces the current operation to be executed regardless
if the "use_external_resource" property is set or not.
required: false
default: false
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API method.
required: false
default: {}
# Every resource uses this property unless noted.
external_resource: &external_resource
use_external_resource:
description: *use_external_resource_desc
type: boolean
default: false
# Every resource uses this property unless noted.
client_config: &client_config
client_config:
description: >
A dictionary of values to pass to authenticate with the API.
type: cloudify.datatypes.ansible_tower.ConnectionConfig
required: false
# Every resource uses this property unless noted.
resource_id: &resource_id
resource_id:
description: *resource_id_desc
type: string
default: ''
node_types:
cloudify.ansible_tower.nodes.User:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.User.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.user.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.user.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Organization:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Organization.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.organization.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.organization.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Team:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Team.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.team.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.team.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.CredentialType:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.CredentialType.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.credential.create_type
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.credential.delete_type
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Credential:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Credential.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.credential.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.credential.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Project:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Project.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.project.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.project.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.JobTemplate:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.JobTemplate.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.job_template.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.job_template.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Job:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Job.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.job.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.job.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Inventory:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Inventory.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.inventory.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.inventory.delete
inputs: *operation_inputs
cloudify.ansible_tower.nodes.Host:
derived_from: cloudify.nodes.Root
properties:
<<: *external_resource
<<: *client_config
<<: *resource_id
resource_config:
description: >
Configuration key-value data to be passed as-is to the corresponding
API endpoint.
type: cloudify.datatypes.ansible_tower.Host.config
required: false
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: plugin.cloudify_ansible_tower.resources.host.create
inputs: *operation_inputs
delete:
implementation: plugin.cloudify_ansible_tower.resources.host.delete
inputs: *operation_inputs
relationships:
cloudify.ansible_tower.relationships.contained_in_organization:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.contained_in_project:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.contained_in_team:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.contained_in_user:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.connected_to_team:
derived_from: cloudify.relationships.connected_to
cloudify.ansible_tower.relationships.connected_to_credential:
derived_from: cloudify.relationships.connected_to
cloudify.ansible_tower.relationships.connected_to_inventory:
derived_from: cloudify.relationships.connected_to
cloudify.ansible_tower.relationships.contained_in_inventory:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.job_template_connected_to_credential:
derived_from: cloudify.relationships.connected_to
source_interfaces:
cloudify.interfaces.relationship_lifecycle:
establish: plugin.cloudify_ansible_tower.resources.job_template.link_credential
unlink: plugin.cloudify_ansible_tower.resources.job_template.unlink_credential
cloudify.ansible_tower.relationships.job_contained_in_job_template:
derived_from: cloudify.relationships.contained_in
cloudify.ansible_tower.relationships.user_has_role:
derived_from: cloudify.relationships.connected_to
source_interfaces:
cloudify.interfaces.relationship_lifecycle:
establish:
implementation: plugin.cloudify_ansible_tower.resources.role.add_user
inputs:
role:
description: >
Permission to assign (Admin, Use, Execute, Read)
default: Admin
required: true
unlink:
implementation: plugin.cloudify_ansible_tower.resources.role.remove_user
inputs:
role:
default: Admin
required: true
cloudify.ansible_tower.relationships.team_has_role:
derived_from: cloudify.relationships.connected_to
source_interfaces:
cloudify.interfaces.relationship_lifecycle:
establish:
implementation: plugin.cloudify_ansible_tower.resources.role.add_team
inputs:
role:
description: >
Permission to assign (Admin, Use, Execute, Read)
default: Admin
required: true
unlink:
implementation: plugin.cloudify_ansible_tower.resources.role.remove_team
inputs:
role:
default: Admin
required: true