forked from vholer/cloudify-occi-puppet-example
-
Notifications
You must be signed in to change notification settings - Fork 0
/
example-blueprint.yaml.m4
127 lines (110 loc) · 3.1 KB
/
example-blueprint.yaml.m4
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
include(example-macros.m4)dnl
tosca_definitions_version: cloudify_dsl_1_2
description: >
This is example Blueprint to show how to interact with FedCloud OCCI and Puppet.
imports:
- http://getcloudify.org/spec/cloudify/3.3.1/types.yaml
- http://getcloudify.org/spec/fabric-plugin/1.3.1/plugin.yaml
- http://getcloudify.org/spec/diamond-plugin/1.3.1/plugin.yaml
- https://raw.githubusercontent.com/vholer/cloudify-occi-plugin-experimental/master/plugin.yaml
- types/puppet.yaml
- types/dbms.yaml
- types/server.yaml
- types/webserver.yaml
inputs:
# OCCI
occi_endpoint:
default: ''
type: string
occi_auth:
default: ''
type: string
occi_username:
default: ''
type: string
occi_password:
default: ''
type: string
occi_user_cred:
default: ''
type: string
occi_ca_path:
default: ''
type: string
occi_voms:
default: False
type: boolean
# contextualization
cc_username:
default: cfy
type: string
cc_public_key:
type: string
cc_private_key_filename:
type: string
cc_data:
default: {}
# VM parameters
os_tpl:
type: string
resource_tpl:
type: string
dsl_definitions:
occi_configuration: &occi_configuration
endpoint: { get_input: occi_endpoint }
auth: { get_input: occi_auth }
username: { get_input: occi_username }
password: { get_input: occi_password }
user_cred: { get_input: occi_user_cred }
ca_path: { get_input: occi_ca_path }
voms: { get_input: occi_voms }
cloud_configuration: &cloud_configuration
username: { get_input: cc_username }
public_key: { get_input: cc_public_key }
data: { get_input: cc_data }
fabric_env: &fabric_env
user: { get_input: cc_username }
key_filename: { get_input: cc_private_key_filename }
agent_configuration: &agent_configuration
install_method: remote
user: { get_input: cc_username }
key: { get_input: cc_private_key_filename }
puppet_config: &puppet_config
repo: 'https://yum.puppetlabs.com/puppetlabs-release-pc1-el-7.noarch.rpm'
package: 'puppet-agent'
download: resources/puppet.tar.gz
node_templates:
scipionNode:
type: _NODE_SERVER_
properties:
name: 'Cloudify example web node'
resource_config:
os_tpl: { get_input: os_tpl }
resource_tpl: { get_input: resource_tpl }
agent_config: *agent_configuration
cloud_config: *cloud_configuration
occi_config: *occi_configuration
fabric_env:
<<: *fabric_env
host_string: { get_attribute: [scipionNode, ip] } # req. by relationship ref.
scipion:
type: _NODE_WEBSERVER_
instances:
deploy: 1
properties:
fabric_env:
<<: *fabric_env
host_string: { get_attribute: [scipionNode, ip] }
puppet_config:
<<: *puppet_config
manifests:
start: manifests/scipion.pp
relationships:
- type: cloudify.relationships.contained_in
target: scipionNode
outputs:
endpoint:
description: Web application endpoint
value:
url: { concat: ['http://', { get_attribute: [scipionNode, ip] }] }
# vim: set syntax=yaml