[SDC-29] Amdocs OnBoard 1707 initial commit.
[sdc.git] / openecomp-be / lib / openecomp-sdc-translator-lib / openecomp-sdc-translator-core / src / test / resources / mock / services / heattotosca / contrail2serviceinstance / connectToNetworkSharedMultiNested / expectedoutputfiles / OCS-fw3ServiceTemplate.yaml
1 tosca_definitions_version: tosca_simple_yaml_1_0_0
2 metadata:
3   template_name: OCS-fw3
4 imports:
5 - openecomp_heat_index:
6     file: openecomp-heat/_index.yml
7 - GlobalSubstitutionTypes:
8     file: GlobalSubstitutionTypesServiceTemplate.yaml
9 topology_template:
10   inputs:
11     service_policy_name:
12       hidden: false
13       immutable: false
14       type: string
15       description: Policy Name
16     st_static_routes_list:
17       hidden: false
18       immutable: false
19       type: string
20       description: List of static routes enabled-disabled
21     st_type:
22       hidden: false
23       immutable: false
24       type: string
25       description: service type
26     st_service_interface_type_list:
27       hidden: false
28       immutable: false
29       type: string
30       description: List of interface types
31     st_mode:
32       hidden: false
33       immutable: false
34       type: string
35       description: service mode
36     Cricket_OCS_protected_net_id:
37       hidden: false
38       immutable: false
39       type: string
40       description: Name of Cricket OCS network
41     oam_mgmt_net_0_id:
42       hidden: false
43       immutable: false
44       type: string
45       description: Name of OAM network
46     start_dst_ports:
47       hidden: false
48       immutable: false
49       type: float
50       description: Start of dst port
51     st_flavor:
52       hidden: false
53       immutable: false
54       type: string
55       description: Flavor
56     availability_zone_1:
57       hidden: false
58       immutable: false
59       type: string
60       description: availability zone
61     service_instance_name:
62       hidden: false
63       immutable: false
64       type: string
65       description: Service instance name
66     st_scaling:
67       hidden: false
68       immutable: false
69       type: string
70       description: Indicates whether service scaling is enabled
71     max_num_fw_instances:
72       hidden: false
73       immutable: false
74       type: float
75       description: maximum number of firewall instances for scaling
76     start_src_ports:
77       hidden: false
78       immutable: false
79       type: float
80       description: Start of src port
81     network_param2:
82       hidden: false
83       immutable: false
84       type: string
85     service_policy_direction:
86       hidden: false
87       immutable: false
88       type: string
89       description: Direction of Policy
90     network_param1:
91       hidden: false
92       immutable: false
93       type: string
94     st_name:
95       hidden: false
96       immutable: false
97       type: string
98       description: Name of service template
99     hsl_direct_net3:
100       hidden: false
101       immutable: false
102       type: string
103     hsl_direct_net4:
104       hidden: false
105       immutable: false
106       type: string
107     HSL_direct_net_gateway:
108       hidden: false
109       immutable: false
110       type: string
111       description: HSL (Logging) network gateway address
112     hsl_direct_net1:
113       hidden: false
114       immutable: false
115       type: string
116     hsl_direct_net2:
117       hidden: false
118       immutable: false
119       type: string
120     st_shared_ip_list:
121       hidden: false
122       immutable: false
123       type: string
124       description: List of shared ip enabled-disabled
125     Cricket_OCS_direct_net_id:
126       hidden: false
127       immutable: false
128       type: string
129       description: Name of Cricket OCS network
130     end_src_ports:
131       hidden: false
132       immutable: false
133       type: float
134       description: End of src port
135     end_dst_ports:
136       hidden: false
137       immutable: false
138       type: float
139       description: End of dst port
140     st_image_name:
141       hidden: false
142       immutable: false
143       type: string
144       description: Name of the image
145     HSL_direct_net_id:
146       hidden: false
147       immutable: false
148       type: string
149       description: Name of HSL (Logging) network
150     HSL_direct_net_cidr:
151       hidden: false
152       immutable: false
153       type: string
154       description: HSL (Logging) network address (CIDR notation)
155   node_templates:
156     service_instance4:
157       type: org.openecomp.resource.abstract.nodes.heat.service_template
158       directives:
159       - substitutable
160       properties:
161         flavor:
162           get_input: st_flavor
163         availability_zone:
164           get_input: availability_zone_1
165         image_name:
166           get_input: st_image_name
167         service_template_filter:
168           substitute_service_template: OCS-fw3_service_instance4ServiceTemplate.yaml
169           count:
170             get_input: max_num_fw_instances
171           scaling_enabled:
172             get_input: st_scaling
173           mandatory: false
174         service_type:
175           get_input: st_type
176         static_routes_list:
177         - token:
178           - get_input: st_static_routes_list
179           - ','
180           - 0
181         - token:
182           - get_input: st_static_routes_list
183           - ','
184           - 1
185         - token:
186           - get_input: st_static_routes_list
187           - ','
188           - 2
189         service_template_name:
190           get_input: st_name
191         service_interface_type_list:
192         - token:
193           - get_input: st_service_interface_type_list
194           - ','
195           - 0
196         - token:
197           - get_input: st_service_interface_type_list
198           - ','
199           - 1
200         - token:
201           - get_input: st_service_interface_type_list
202           - ','
203           - 2
204         service_instance_name:
205           get_input: service_instance_name
206         interface_list:
207         - virtual_network:
208             get_input: network_param1
209         - virtual_network:
210             get_input: network_param1
211         - virtual_network:
212             get_input: network_param2
213         service_mode:
214           get_input: st_mode
215         shared_ip_list:
216         - token:
217           - get_input: st_shared_ip_list
218           - ','
219           - 0
220         - token:
221           - get_input: st_shared_ip_list
222           - ','
223           - 1
224         - token:
225           - get_input: st_shared_ip_list
226           - ','
227           - 2
228       requirements:
229       - dependency:
230           capability: tosca.capabilities.Node
231           node: hsl_direct_net
232           relationship: tosca.relationships.DependsOn
233     hsl_direct_net:
234       type: org.openecomp.resource.vl.nodes.heat.network.contrail.VirtualNetwork
235       properties:
236         network_name:
237           get_input: HSL_direct_net_id
238         subnets:
239           hsl_ip_subnet:
240             cidr:
241               get_input: HSL_direct_net_cidr
242             gateway_ip:
243               get_input: HSL_direct_net_gateway
244     service_policy:
245       type: org.openecomp.resource.vfc.rules.nodes.heat.network.contrail.NetworkRules
246       properties:
247         entries:
248           policy_rule:
249           - src_ports:
250             - start_port:
251                 get_input: start_src_ports
252               end_port:
253                 get_input: end_src_ports
254             protocol: any
255             action_list:
256               apply_service:
257               - service_instance4
258             dst_addresses:
259             - virtual_network:
260                 get_input: Cricket_OCS_direct_net_id
261             dst_ports:
262             - start_port:
263                 get_input: start_dst_ports
264               end_port:
265                 get_input: end_dst_ports
266             src_addresses:
267             - virtual_network:
268                 get_input: Cricket_OCS_protected_net_id
269             direction:
270               get_input: service_policy_direction
271         name:
272           get_input: service_policy_name
273       requirements:
274       - dependency:
275           capability: tosca.capabilities.Node
276           node: service_instance4
277           relationship: tosca.relationships.DependsOn
278   groups:
279     OCS-fw3_group:
280       type: org.openecomp.groups.heat.HeatStack
281       properties:
282         heat_file: ../Artifacts/OCS-fw3.yml
283         description: |
284           Based on the following reference for the HOT-DMZ-FW template: Version 3.5 8-10-2015 (Authors: Art Mishurov,am254u & Johhny Chen, jc3066) - HOT-DMZ-FW template that creates two DMZ networks (direct and protected) with a scaled out firewall service between the two.
285       members:
286       - service_instance4
287       - hsl_direct_net
288       - service_policy
289   substitution_mappings:
290     node_type: org.openecomp.resource.abstract.nodes.heat.OCS-fw3
291     capabilities:
292       link_hsl_direct_net:
293       - hsl_direct_net
294       - link
295       feature_service_policy:
296       - service_policy
297       - feature
298       feature_service_instance4:
299       - service_instance4
300       - feature
301       attachment_hsl_direct_net:
302       - hsl_direct_net
303       - attachment
304       feature_hsl_direct_net:
305       - hsl_direct_net
306       - feature
307       end_point_hsl_direct_net:
308       - hsl_direct_net
309       - end_point
310     requirements:
311       dependency_service_instance4:
312       - service_instance4
313       - dependency
314       dependency_hsl_direct_net:
315       - hsl_direct_net
316       - dependency
317       link_port_0_service_instance4:
318       - service_instance4
319       - link_port_0
320       link_port_1_service_instance4:
321       - service_instance4
322       - link_port_1
323       network_service_policy:
324       - service_policy
325       - network
326       dependency_service_policy:
327       - service_policy
328       - dependency
329       link_port_2_service_instance4:
330       - service_instance4
331       - link_port_2