-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathplugin.yaml
72 lines (63 loc) · 2.76 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
plugins:
# Name could be anything, this name is what appears on the beginning of operation
# mappings.
plugin_name:
# Could be 'central_deployment_agent' or 'host_agent'.
# If 'central_deployment_agent', this plugin will be executed on the
# deployment dedicated agent, other wise it will be executed on the host agent.
executor: central_deployment_agent
# URL to archive containing the plugin or name of directory containing
# the plugin if it is included in the the blueprint directory under the
# "plugins" directory.
# Usage of "source" is supported, but not recommended, as it results in the
# plugin going through `pip` installation on each and every agent (thus requiring
# access to the `pip` repository/mirror, compilers and so forth).
# Usage of plugin Wagon files, whenever possible, is recommended.
source: https://github.com/cloudify-cosmo/cloudify-plugin-template/archive/master.zip
# The plugin's name, as it is known to Cloudify Manager. Cloudify Manager uses this
# name to index the plugin in the plugins table.
package_name: 'ENTER-PLUGIN-NAME-HERE'
# The plugin's version. NOTE - it is recommended that this value is quoted, in order to
# ensure it passes YAML parsing as a string (by default, the value "1.0" [without quotes]
# will be parsed as a float).
package_version: '1.0'
data_types:
# you can build your data types for the properties that you will use inside the node_types
cloudify.types.template.MockedConfig:
properties:
mock_host:
description: mock host.
type: string
default: ''
required: true
mock_username:
description: mock username.
type: string
default: ''
mock_password:
description: mock password.
type: string
default: ''
dsl_definitions:
# you can define custom dsl defintions
# [ anchors that you can use to define common values or definitions between node definitions ]
host_config: &host_config
host_config:
type: cloudify.types.template.MockedConfig
description: Your mocked host configuration.
required: true
node_types:
# you can define your node_types here
cloudify.nodes.template.MockHost:
# you can use the derived_form
# [ to inherit the properties and interfaces of the node you are referencing ]
derived_from: cloudify.nodes.Root
# here you can add the properties that is relevant for you to interact with from the plugin python code
properties:
<<: *host_config
interfaces:
# you can define the lifecycle operation
# and whatever operation that you may need this node_type to support
cloudify.interfaces.lifecycle:
create:
implementation: plugin_name.plugin.tasks.my_task