-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopenstack.yaml
162 lines (145 loc) · 4.96 KB
/
openstack.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
tosca_definitions_version: cloudify_dsl_1_2
imports:
- http://www.getcloudify.org/spec/cloudify/3.3.1/types.yaml
- http://www.getcloudify.org/spec/openstack-plugin/1.3.1/plugin.yaml
- http://www.getcloudify.org/spec/diamond-plugin/1.3.1/plugin.yaml
inputs:
ssc_address:
description: Address of SSC to send load to
type: string
ssc_port:
description: Access port of SSC to send load to
type: integer
default: 5060
sip_domain:
description: SIP domain name
type: string
default: cloudify.test
area_codes:
description: >
Comma-separated list of area codes for which the numbers XXX-555-0000 to XXX-555-1999 have
been provisioned and reserved for use by the load generator.
type: string
sip_password:
description: SIP password that each load SIP account is authorized with
type: string
default: 7kkzTyGW
call_rate:
description: Calls per second per load server
type: integer
default: 1
ubuntu_image_id:
description: UUID of an Ubuntu 14.04 image
type: string
default: 1276d72f-6504-4df1-aa1c-acf161286b6e # Ubuntu 14.04
# TODO: replace this with a new "load" flavour.
clearwater_flavor_name:
description: Name of the flavor to use for Clearwater instances
type: string
default: clearwater.core
ntp_servers:
description: Comma-separated list of NTP IP addresses
type: string
default: 10.254.123.1,10.254.123.2,10.254.123.3
management_cidr:
description: Management subnet
type: string
default: 10.67.79.0/24
outputs:
calls_generated_statstic:
description: Query locator of the load generator's statistics
# TODO: actually produce something like: /cc3-20\..*?\.LoadCollector_calls_total/, with deployment id - or maybe even entire json
value: "LoadCollector_calls_total"
node_types:
metaswitch.nodes.MonitoredSoftwareComponent:
derived_from: cloudify.nodes.SoftwareComponent
properties:
collectors_config: {}
relationships:
metaswitch.relationships.load_generator_in_cluster:
derived_from: cloudify.relationships.connected_to
properties:
connection_type:
default: all_to_one
source_interfaces:
cloudify.interfaces.relationship_lifecycle:
preconfigure:
implementation: scripts/relationships/load_cluster/add_instance.py
unlink:
implementation: scripts/relationships/load_cluster/remove_instance.py
node_templates:
default_security_group:
type: cloudify.openstack.nodes.SecurityGroup
properties:
security_group:
description: Default security group
rules:
- remote_ip_prefix: { get_input: management_cidr }
protocol: null
port: null
load_cluster:
type: cloudify.nodes.Root
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: scripts/tasks/load_cluster/create.py
executor: central_deployment_agent
inputs:
area_codes: { get_input: area_codes }
load_vm:
type: cloudify.openstack.nodes.Server
instances:
deploy: 1
properties:
image: { get_input: ubuntu_image_id }
flavor: { get_input: clearwater_flavor_name }
agent_config:
user: ubuntu
interfaces:
cloudify.interfaces.monitoring_agent:
install:
implementation: diamond.diamond_agent.tasks.install
inputs:
diamond_config:
interval: 20
start: diamond.diamond_agent.tasks.start
stop: diamond.diamond_agent.tasks.stop
uninstall: diamond.diamond_agent.tasks.uninstall
relationships:
- type: cloudify.openstack.server_connected_to_security_group
target: default_security_group
load:
type: metaswitch.nodes.MonitoredSoftwareComponent
properties:
collectors_config:
LoadCollector:
path: collectors/load.py
CPUCollector: {}
interfaces:
cloudify.interfaces.lifecycle:
create:
implementation: scripts/tasks/load_software/create.py
inputs:
ntp_servers: { get_input: ntp_servers }
start:
implementation: scripts/tasks/load_software/start.sh
inputs:
ssc_address: { get_input: ssc_address }
ssc_port: { get_input: ssc_port }
sip_domain: { get_input: sip_domain }
sip_password: { get_input: sip_password }
call_rate: { get_input: call_rate }
cloudify.interfaces.monitoring:
start:
implementation: diamond.diamond_agent.tasks.add_collectors
inputs:
collectors_config: { get_property: [SELF, collectors_config] }
stop:
implementation: diamond.diamond_agent.tasks.del_collectors
inputs:
collectors_config: { get_property: [SELF, collectors_config] }
relationships:
- type: cloudify.relationships.contained_in
target: load_vm
- type: metaswitch.relationships.load_generator_in_cluster
target: load_cluster