Add 4 node stack type for hwvtep suites
[releng/builder.git] / openstack-hot / csit-4-instance-type.yaml
1 ---
2 heat_template_version: 2016-04-08
3
4 parameters:
5     job_name:
6         type: string
7         description: Name of job running this template
8     silo:
9         type: string
10         description: Jenkins Silo job is running in (typically releng|sandbox)
11     vm_0_count:
12         type: number
13         description: Number of VMs for 1st VM type
14     vm_0_flavor:
15         type: string
16         default: 1 GB General Purpose v1
17         description: Flavor to run instance on for 1st VM type
18     vm_0_image:
19         type: string
20         description: Image to run instance on for 1st VM type
21     vm_1_count:
22         type: number
23         description: Number of VMs for 2nd VM type
24     vm_1_flavor:
25         type: string
26         default: 1 GB General Purpose v1
27         description: Flavor to run instance on for 2nd VM type
28     vm_1_image:
29         type: string
30         description: Image to run instance on for 2nd VM type
31     vm_2_count:
32         type: number
33         description: Number of VMs for 3rd VM type
34     vm_2_flavor:
35         type: string
36         default: 1 GB General Purpose v1
37         description: Flavor to run instance on for 3rd VM type
38     vm_2_image:
39         type: string
40     vm_3_count:
41         type: number
42         description: Number of VMs for 3rd VM type
43     vm_3_flavor:
44         type: string
45         default: 1 GB General Purpose v1
46         description: Flavor to run instance on for 3rd VM type
47     vm_3_image:
48         type: string
49
50 resources:
51     vm_0_group:
52         type: "OS::Heat::ResourceGroup"
53         properties:
54             count: {get_param: vm_0_count}
55             resource_def:
56                 type: generic-server.yaml
57                 properties:
58                     job_name: {get_param: job_name}
59                     silo: {get_param: silo}
60                     ssh_key: {get_param: silo}
61                     index: "%index%"
62                     vm_flavor: {get_param: vm_0_flavor}
63                     vm_image: {get_param: vm_0_image}
64
65     vm_1_group:
66         type: "OS::Heat::ResourceGroup"
67         properties:
68             count: {get_param: vm_1_count}
69             resource_def:
70                 type: generic-server.yaml
71                 properties:
72                     job_name: {get_param: job_name}
73                     silo: {get_param: silo}
74                     ssh_key: {get_param: silo}
75                     index: "%index%"
76                     vm_flavor: {get_param: vm_1_flavor}
77                     vm_image: {get_param: vm_1_image}
78
79     vm_2_group:
80         type: "OS::Heat::ResourceGroup"
81         properties:
82             count: {get_param: vm_2_count}
83             resource_def:
84                 type: generic-server.yaml
85                 properties:
86                     job_name: {get_param: job_name}
87                     silo: {get_param: silo}
88                     ssh_key: {get_param: silo}
89                     index: "%index%"
90                     vm_flavor: {get_param: vm_2_flavor}
91                     vm_image: {get_param: vm_2_image}
92     vm_3_group:
93         type: "OS::Heat::ResourceGroup"
94         properties:
95             count: {get_param: vm_3_count}
96             resource_def:
97                 type: generic-server.yaml
98                 properties:
99                     job_name: {get_param: job_name}
100                     silo: {get_param: silo}
101                     ssh_key: {get_param: silo}
102                     index: "%index%"
103                     vm_flavor: {get_param: vm_3_flavor}
104                     vm_image: {get_param: vm_3_image}
105
106 outputs:
107     vm_0_ips:
108         description: IP addresses of the 1st vm types
109         value: {get_attr: [vm_0_group, ip]}
110     vm_1_ips:
111         description: IP addresses of the 2nd vm types
112         value: {get_attr: [vm_1_group, ip]}
113     vm_2_ips:
114         description: IP addresses of the 3rd vm types
115         value: {get_attr: [vm_2_group, ip]}
116     vm_3_ips:
117         description: IP addresses of the 4th vm types
118         value: {get_attr: [vm_3_group, ip]}