forked from Metaswitch/clearwater-heat
-
Notifications
You must be signed in to change notification settings - Fork 0
/
security-groups.yaml
371 lines (354 loc) · 13.1 KB
/
security-groups.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
# Copyright (C) Metaswitch Networks 2017
# If license terms are provided to you in a COPYING file in the root directory
# of the source code repository by which you are accessing this code, then
# the license outlined in that COPYING file applies to your use.
# Otherwise no rights are granted except for those provided to you by
# Metaswitch Networks in a separate written agreement.
heat_template_version: 2013-05-23
description: >
Security Groups for Clearwater to use
parameters:
name_prefix:
type: string
description: Security group name prefix
default: clearwater
resources:
base_mgmt:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-base-mgmt } }
description: Base security group for all Clearwater nodes (management)
rules:
# All egress traffic
- direction: egress
ethertype: IPv4
- direction: egress
ethertype: IPv6
# ICMP
- protocol: icmp
# SSH
- protocol: tcp
port_range_min: 22
port_range_max: 22
# SNMP
- protocol: udp
port_range_min: 161
port_range_max: 161
# etcd
- protocol: tcp
port_range_min: 2380
port_range_max: 2380
remote_mode: remote_group_id
#remote_group_id: { get_resource: base_mgmt } # omit remote_group_id to reference yourself
- protocol: tcp
port_range_min: 4000
port_range_max: 4000
remote_mode: remote_group_id
#remote_group_id: { get_resource: base_mgmt } # omit remote_group_id to reference yourself
dns:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-dns } }
description: Security group for DNS nodes
rules:
# All egress traffic
- direction: egress
ethertype: IPv4
- direction: egress
ethertype: IPv6
# ICMP
- protocol: icmp
# SSH
- protocol: tcp
port_range_min: 22
port_range_max: 22
# DNS
- protocol: udp
port_range_min: 53
port_range_max: 53
- protocol: tcp
port_range_min: 53
port_range_max: 53
ellis_mgmt:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-ellis-mgmt } }
description: Security group for Ellis nodes (management)
rules:
# HTTP
- protocol: tcp
port_range_min: 80
port_range_max: 80
# HTTPS
- protocol: tcp
port_range_min: 443
port_range_max: 443
bono_sig:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-bono-sig } }
description: Security group for Bono nodes (signaling)
rules:
# STUN/TURN
- protocol: udp
port_range_min: 3478
port_range_max: 3478
- protocol: tcp
port_range_min: 3478
port_range_max: 3478
# Internal SIP
- protocol: tcp
port_range_min: 5058
port_range_max: 5058
remote_mode: remote_group_id
#remote_group_id: { get_resource: bono_sig } # omit remote_group_id to reference yourself
- protocol: tcp
port_range_min: 5058
port_range_max: 5058
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
# External SIP
- protocol: udp
port_range_min: 5060
port_range_max: 5060
- protocol: tcp
port_range_min: 5060
port_range_max: 5060
# External SIP/WebSocket
- protocol: tcp
port_range_min: 5062
port_range_max: 5062
# RTP
- protocol: udp
port_range_min: 32768
port_range_max: 65535
sprout_sig_outbound:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-sprout-sig-outbound } }
description: Security group for Sprout nodes outbound traffic (signaling)
rules:
# Internal SIP
- protocol: tcp
port_range_min: 5052
port_range_max: 5052
remote_mode: remote_group_id
#remote_group_id: { get_resource: sprout_sig_outbound } # omit remote_group_id to reference yourself
- protocol: tcp
port_range_min: 5054
port_range_max: 5054
remote_mode: remote_group_id
#remote_group_id: { get_resource: sprout_sig_outbound } # omit remote_group_id to reference yourself
sprout_sig_inbound:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-sprout-sig-inbound } }
description: Security group for Sprout nodes inbound traffic (signaling)
rules:
# Internal SIP
- protocol: tcp
port_range_min: 5052
port_range_max: 5052
remote_mode: remote_group_id
remote_group_id: { get_resource: bono_sig }
- protocol: tcp
port_range_min: 5054
port_range_max: 5054
remote_mode: remote_group_id
remote_group_id: { get_resource: bono_sig }
# Chronos timer pops
- protocol: tcp
port_range_min: 9888
port_range_max: 9888
remote_mode: remote_group_id
remote_group_id: { get_resource: vellum_sig_outbound }
# Notifications from Homestead
- protocol: tcp
port_range_min: 9888
port_range_max: 9888
remote_mode: remote_group_id
remote_group_id: { get_resource: dime_sig }
homer_mgmt:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-homer-mgmt } }
description: Security group for Homer nodes (management)
rules:
# Ut/HTTP
- protocol: tcp
port_range_min: 7888
port_range_max: 7888
- protocol: tcp
port_range_min: 7888
port_range_max: 7888
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
homer_sig:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-homer-sig } }
description: Security group for Homer nodes (signaling)
rules:
# Ut/HTTP
- protocol: tcp
port_range_min: 7888
port_range_max: 7888
- protocol: tcp
port_range_min: 7888
port_range_max: 7888
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
- protocol: tcp
port_range_min: 9160
port_range_max: 9160
remote_mode: remote_group_id
#remote_group_id: { get_resource: homer_sig } # omit remote_group_id to reference yourself
dime_mgmt:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-dime-mgmt } }
description: Security group for Dime nodes (management)
rules:
# REST-ful Provisioning API
- protocol: tcp
port_range_min: 8889
port_range_max: 8889
remote_mode: remote_group_id
remote_group_id: { get_resource: ellis_mgmt }
dime_sig:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-dime-sig } }
description: Security group for Dime nodes (signaling)
rules:
# Cx-like HTTP API
- protocol: tcp
port_range_min: 8888
port_range_max: 8888
remote_mode: remote_group_id
remote_group_id: { get_resource: bono_sig }
- protocol: tcp
port_range_min: 8888
port_range_max: 8888
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
# Rf-like/HTTP API
- protocol: tcp
port_range_min: 10888
port_range_max: 10888
remote_mode: remote_group_id
remote_group_id: { get_resource: bono_sig }
- protocol: tcp
port_range_min: 10888
port_range_max: 10888
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
# Chronos timer pops
- protocol: tcp
port_range_min: 10888
port_range_max: 10888
remote_mode: remote_group_id
remote_group_id: { get_resource: vellum_sig_outbound }
vellum_sig_outbound:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-vellum-sig-outbound } }
description: Security group for Vellum nodes outbound traffic (signaling)
rules:
# Chronos
- protocol: tcp
port_range_min: 7253
port_range_max: 7253
remote_mode: remote_group_id
#remote_group_id: { get_resource: vellum_sig_outbound } # omit remote_group_id to reference yourself
# Cassandra
- protocol: tcp
port_range_min: 7000
port_range_max: 7000
remote_mode: remote_group_id
#remote_group_id: { get_resource: vellum_sig_outbound } # omit remote_group_id to reference yourself
# Memcached listening to Astaire
- protocol: tcp
port_range_min: 11211
port_range_max: 11211
remote_mode: remote_group_id
#remote_group_id: { get_resource: vellum_sig_outbound } # omit remote_group_id to reference yourself
vellum_sig_inbound:
type: OS::Neutron::SecurityGroup
properties:
name: { str_replace: { params: { __name_prefix__: { get_param: "name_prefix" } }, template: __name_prefix__-vellum-sig-inbound } }
description: Security group for Vellum nodes inbound traffic (signaling)
rules:
# Astaire
- protocol: tcp
port_range_min: 11311
port_range_max: 11311
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
# Astaire
- protocol: tcp
port_range_min: 11311
port_range_max: 11311
remote_mode: remote_group_id
remote_group_id: { get_resource: dime_sig }
# Chronos
- protocol: tcp
port_range_min: 7253
port_range_max: 7253
remote_mode: remote_group_id
remote_group_id: { get_resource: sprout_sig_outbound }
# Chronos
- protocol: tcp
port_range_min: 7253
port_range_max: 7253
remote_mode: remote_group_id
remote_group_id: { get_resource: dime_sig }
# Cassandra Thrift
- protocol: tcp
port_range_min: 9160
port_range_max: 9160
remote_mode: remote_group_id
remote_group_id: { get_resource: dime_sig }
# Cassandra Thrift
- protocol: tcp
port_range_min: 9160
port_range_max: 9160
remote_mode: remote_group_id
remote_group_id: { get_resource: homer_sig }
outputs:
base_mgmt:
description: Base security group for all Clearwater nodes (management)
value: { get_resource: base_mgmt }
dns:
description: Security group for DNS nodes
value: { get_resource: dns }
ellis_mgmt:
description: Security group for Ellis nodes (managment)
value: { get_resource: ellis_mgmt }
bono_sig:
description: Security group for Bono nodes (signaling)
value: { get_resource: bono_sig }
sprout_sig_outbound:
description: Security group for Sprout nodes outbound traffic (signaling)
value: { get_resource: sprout_sig_outbound }
sprout_sig_inbound:
description: Security group for Sprout nodes inbound traffic (signaling)
value: { get_resource: sprout_sig_inbound }
homer_mgmt:
description: Security group for Homer nodes (management)
value: { get_resource: homer_mgmt }
homer_sig:
description: Security group for Homer nodes (signaling)
value: { get_resource: homer_sig }
dime_mgmt:
description: Security group for Dime nodes (management)
value: { get_resource: dime_mgmt }
dime_sig:
description: Security group for Dime nodes (signaling)
value: { get_resource: dime_sig }
vellum_sig_outbound:
description: Security group for Vellum nodes outbound traffic (signaling)
value: { get_resource: vellum_sig_outbound }
vellum_sig_inbound:
description: Security group for Vellum nodes inbound traffic (signaling)
value: { get_resource: vellum_sig_inbound }