Merge "Auto Generated INFO.yaml file"
[samplevnf.git] / VNFs / DPPD-PROX / helper-scripts / openstackrapid / 3VMsriovrapid.yaml
1 ##
2 ## Copyright (c) 2010-2017 Intel Corporation
3 ##
4 ## Licensed under the Apache License, Version 2.0 (the "License");
5 ## you may not use this file except in compliance with the License.
6 ## You may obtain a copy of the License at
7 ##
8 ##     http://www.apache.org/licenses/LICENSE-2.0
9 ##
10 ## Unless required by applicable law or agreed to in writing, software
11 ## distributed under the License is distributed on an "AS IS" BASIS,
12 ## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 ## See the License for the specific language governing permissions and
14 ## limitations under the License.
15 ##
16
17 heat_template_version: 2016-04-08
18 description: RAPID stack (Rapid Automated Performance Indication for Dataplane)
19 parameters:
20   image:
21     type: string
22     label: Image name or ID
23     description: Image to be used for compute instance
24     default: RapidVM
25   flavor:
26     type: string
27     label: Flavor
28     description: Type of instance (flavor) to be used
29     default: prox_flavor
30   key:
31     type: string
32     label: Key name
33     description: Name of key-pair to be used for compute instance
34     default: prox
35   dataplane_network:
36     type: string
37     label: Private network name or ID
38     description: Network to attach instance to.
39     default: dataplane-network
40   internal_network:
41     type: string
42     label: Private network name or ID
43     description: Network to attach instance to.
44     default: admin_internal_net
45   floating_network:
46     type: string
47     label: Floating network name or ID
48     description: Public Network to attach instance to.
49     default: admin_floating_net
50   availability_zone:
51     type: string
52     description: The Availability Zone to launch the instance.
53     default: nova
54   vm1_availability_zone:
55     type: string
56     description: The Availability Zone to launch the instance.
57     default: nova
58   vm1_sriov_port:
59     type: string
60     description: The sriov port to be used by VM1
61     default: Port1
62   vm2_sriov_port:
63     type: string
64     description: The sriov port to be used by VM2
65     default: Port2
66   vm3_sriov_port:
67     type: string
68     description: The sriov port to be used by VM3
69     default: Port3
70
71 resources:
72   vm1_admin_port:
73      type: OS::Neutron::Port
74      properties:
75        network: {get_param: internal_network}
76        security_groups:
77          - default
78   vm1_floating_ip:
79      type: OS::Neutron::FloatingIP
80      properties:
81        floating_network: {get_param: floating_network}
82        port_id: {get_resource: vm1_admin_port}
83   vm1:
84     type: OS::Nova::Server
85     properties:
86       availability_zone: { get_param: vm1_availability_zone }
87       user_data:
88         get_file: prox_user_data.sh
89       key_name: { get_param: key }
90       image: { get_param: image }
91       flavor: { get_param: flavor }
92       networks:
93         - port: {get_resource: vm1_admin_port}
94         - port: {get_param: vm1_sriov_port}
95   vm2_admin_port:
96      type: OS::Neutron::Port
97      properties:
98        network: {get_param: internal_network}
99        security_groups:
100          - default
101   vm2_floating_ip:
102      type: OS::Neutron::FloatingIP
103      properties:
104        floating_network: {get_param: floating_network}
105        port_id: {get_resource: vm2_admin_port}
106   vm2:
107     type: OS::Nova::Server
108     properties:
109       availability_zone: { get_param: availability_zone }
110       user_data:
111         get_file: prox_user_data.sh
112       key_name: { get_param: key }
113       image: { get_param: image }
114       flavor: { get_param: flavor }
115       networks:
116         - port: {get_resource: vm2_admin_port}
117         - port: {get_param: vm2_sriov_port}
118   vm3_admin_port:
119      type: OS::Neutron::Port
120      properties:
121        network: {get_param: internal_network}
122        security_groups:
123          - default
124   vm3_floating_ip:
125      type: OS::Neutron::FloatingIP
126      properties:
127        floating_network: {get_param: floating_network}
128        port_id: {get_resource: vm3_admin_port}
129   vm3:
130     type: OS::Nova::Server
131     properties:
132       availability_zone: { get_param: availability_zone }
133       user_data:
134         get_file: prox_user_data.sh
135       key_name: { get_param: key }
136       image: { get_param: image }
137       flavor: { get_param: flavor }
138       networks:
139         - port: {get_resource: vm3_admin_port}
140         - port: {get_param: vm3_sriov_port}
141
142 outputs:
143   total_number_of_VMs:
144     description: Number of VMs created by this stack
145     value: 3
146   vm1_private_ip:
147     description: IP address of VM1 admin port
148     value: { get_attr: [vm1_admin_port, fixed_ips, 0, ip_address] }
149   vm1_public_ip:
150     description: Floating IP address of VM1 in public network
151     value: { get_attr: [ vm1_floating_ip, floating_ip_address ] }
152   vm1_dataplane_ip:
153     description: IP address of VM1 dataplane port
154     value: { get_attr: [vm1, networks,{get_param: dataplane_network},0] }
155   vm1_dataplane_mac:
156     description: The MAC address of VM1 dataplane port
157     value: { get_attr: [vm1, addresses, {get_param: dataplane_network}] }
158   vm2_private_ip:
159     description: IP address of VM2 admin port
160     value: { get_attr: [vm2_admin_port, fixed_ips, 0, ip_address] }
161   vm2_public_ip:
162     description: Floating IP address of VM2 in public network
163     value: { get_attr: [ vm2_floating_ip, floating_ip_address ] }
164   vm2_dataplane_ip:
165     description: IP address of VM2 dataplane port
166     value: { get_attr: [vm2, networks,{get_param: dataplane_network},0] }
167   vm2_dataplane_mac:
168     description: The MAC address of VM2 dataplane port
169     value: { get_attr: [vm2, addresses, {get_param: dataplane_network}]}
170   vm3_private_ip:
171     description: IP address of VM3 admin port
172     value: { get_attr: [vm3_admin_port, fixed_ips, 0, ip_address] }
173   vm3_public_ip:
174     description: Floating IP address of VM3 in public network
175     value: { get_attr: [ vm3_floating_ip, floating_ip_address ] }
176   vm3_dataplane_ip:
177     description: IP address of VM3 dataplane port
178     value: { get_attr: [vm3, networks,{get_param: dataplane_network},0] }
179   vm3_dataplane_mac:
180     description: The MAC address of VM3 dataplane port
181     value: { get_attr: [vm3, addresses, {get_param: dataplane_network}]}