c464235f6b15bedbcb417e2b299cb1dbb67f0de4
[apex-tripleo-heat-templates.git] / overcloud-source.yaml
1 Description: Nova API,Keystone,Heat Engine and API,Glance,Neutron,Dedicated MySQL
2   server,Dedicated RabbitMQ Server,Group of Nova Computes
3 HeatTemplateFormatVersion: '2012-12-12'
4 Parameters:
5   AdminPassword:
6     Default: unset
7     Description: The password for the keystone admin account, used for monitoring, querying neutron etc.
8     Type: String
9     NoEcho: true
10   AdminToken:
11     Default: unset
12     Description: The keystone auth secret.
13     Type: String
14   CinderPassword:
15     Default: unset
16     Description: The password for the cinder service account, used by cinder-api.
17     Type: String
18     NoEcho: true
19   Flavor:
20     Default: baremetal
21     Description: Flavor to request when deploying.
22     Type: String
23   GlancePassword:
24     Default: unset
25     Description: The password for the glance service account, used by the glance services.
26     Type: String
27     NoEcho: true
28   HeatPassword:
29     Default: unset
30     Description: The password for the Heat service account, used by the Heat services.
31     Type: String
32     NoEcho: true
33   KeyName:
34     Default: default
35     Description: Name of an existing EC2 KeyPair to enable SSH access to the instances
36     Type: String
37   NeutronPassword:
38     Default: unset
39     Description: The password for the neutron service account, used by neutron agents.
40     Type: String
41     NoEcho: true
42   NovaComputeDriver:
43     Default: libvirt.LibvirtDriver
44     Type: String
45   NovaComputeLibvirtType:
46     Default: ''
47     Type: String
48   NovaImage:
49     Type: String
50     Default: overcloud-compute
51   NovaPassword:
52     Default: unset
53     Description: The password for the nova service account, used by nova-api.
54     Type: String
55     NoEcho: true
56   PowerUserName:
57     Default: stack
58     Description: What username to ssh to the virtual power host with.
59     Type: String
60   NeutronPublicInterface:
61     Default: eth0
62     Description: What interface to bridge onto br-ex for network nodes.
63     Type: String
64   NeutronPublicInterfaceDefaultRoute:
65     Default: ''
66     Description: A custom default route for the NeutronPublicInterface.
67     Type: String
68   NeutronPublicInterfaceIP:
69     Default: ''
70     Description: A custom IP address to put onto the NeutronPublicInterface.
71     Type: String
72   NeutronPublicInterfaceRawDevice:
73     Default: ''
74     Description: If set, the public interface is a vlan with this device as the raw device.
75     Type: String
76   notcomputeImage:
77     Type: String
78     Default: overcloud-control
79 Resources:
80   AccessPolicy:
81     Properties:
82       AllowedResources:
83       - notcompute
84       - notcomputeConfig
85     Type: OS::Heat::AccessPolicy
86   ComputeAccessPolicy:
87     Properties:
88       AllowedResources:
89       - NovaCompute0
90       - NovaCompute0Config
91     Type: OS::Heat::AccessPolicy
92   Key:
93     Properties:
94       UserName:
95         Ref: User
96     Type: AWS::IAM::AccessKey
97   CompletionCondition:
98     Type: AWS::CloudFormation::WaitCondition
99     DependsOn: notcompute
100     Properties:
101       Handle: {Ref: CompletionHandle}
102       Count: '1'
103       Timeout: '1800'
104   CompletionHandle:
105     Type: AWS::CloudFormation::WaitConditionHandle
106   ComputeKey:
107     Properties:
108       UserName:
109         Ref: ComputeUser
110     Type: AWS::IAM::AccessKey
111   ComputeUser:
112     Properties:
113       Policies:
114       - Ref: ComputeAccessPolicy
115     Type: AWS::IAM::User
116   NovaCompute0Config:
117     Type: FileInclude
118     Path: nova-compute-instance.yaml
119     SubKey: Resources.NovaCompute0Config
120     Parameters:
121         NovaApiHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ] }
122         KeystoneHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ] }
123         RabbitHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ] }
124         NeutronHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ] }
125         GlanceHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ] }
126         NovaDSN: {"Fn::Join": ['', ['mysql://nova:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ]}, '/nova']]}
127         NeutronDSN: {"Fn::Join": ['', ['mysql://neutron:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notcompute, networks]} ]} ]}, '/neutron']]}
128         NeutronNetworkType: "gre"
129         NeutronEnableTunnelling: "True"
130         NeutronNetworkVLANRanges: ""
131         NeutronBridgeMappings: ""
132         RabbitPassword: "guest"
133   NovaCompute0:
134     Type: FileInclude
135     Path: nova-compute-instance.yaml
136     SubKey: Resources.NovaCompute0
137   User:
138     Properties:
139       Policies:
140       - Ref: AccessPolicy
141     Type: AWS::IAM::User
142   notcomputeConfig:
143     Type: AWS::AutoScaling::LaunchConfiguration
144     Properties:
145       ImageId: '0'
146       InstanceType: '0'
147     Metadata:
148       OpenStack::Heat::Stack: {}
149       Openstack::ImageBuilder::Elements:
150       - boot-stack
151       - heat-cfntools
152       - heat-localip
153       - neutron-network-node
154       admin-password:
155         Ref: AdminPassword
156       admin-token:
157         Ref: AdminToken
158       bootstack:
159         public_interface_ip:
160           Ref: NeutronPublicInterfaceIP
161       cinder:
162         db: mysql://cinder:unset@localhost/cinder
163         volume_size_mb: '5000'
164         service-password:
165           Ref: CinderPassword
166       completion-handle:
167         Ref: CompletionHandle
168       controller-address:
169         Fn::Select:
170          - 0
171          - Fn::Select:
172              - 'ctlplane'
173              - Fn::GetAtt:
174                - notcompute
175                - networks
176       db-password: unset
177       glance:
178         db: mysql://glance:unset@localhost/glance
179         host:
180           Fn::Select:
181            - 0
182            - Fn::Select:
183                - 'ctlplane'
184                - Fn::GetAtt:
185                  - notcompute
186                  - networks
187         service-password:
188           Ref: GlancePassword
189       os-collect-config:
190         cfn:
191           access_key_id:
192             Ref: Key
193           path: notcomputeConfig.Metadata
194           secret_access_key:
195             Fn::GetAtt:
196             - Key
197             - SecretAccessKey
198           stack_name:
199             Ref: AWS::StackName
200       heat:
201         admin_password:
202           Ref: HeatPassword
203         admin_tenant_name: service
204         admin_user: heat
205         auth_encryption_key: unset___________
206         db: mysql://heat:unset@localhost/heat
207         heat_watch_server_url:
208           Fn::Join:
209             - ''
210             - - 'http://'
211               - Fn::Select:
212                 - 0
213                 - Fn::Select:
214                   - 'ctlplane'
215                   - Fn::GetAtt:
216                     - notcompute
217                     - networks
218               - ':8003'
219         metadata_server_url:
220           Fn::Join:
221             - ''
222             - - 'http://'
223               - Fn::Select:
224                 - 0
225                 - Fn::Select:
226                   - 'ctlplane'
227                   - Fn::GetAtt:
228                     - notcompute
229                     - networks
230               - ':8000'
231         waitcondition_server_url:
232           Fn::Join:
233             - ''
234             - - 'http://'
235               - Fn::Select:
236                 - 0
237                 - Fn::Select:
238                   - 'ctlplane'
239                   - Fn::GetAtt:
240                     - notcompute
241                     - networks
242               - ':8000/v1/waitcondition'
243       keystone:
244         db: mysql://keystone:unset@localhost/keystone
245         host:
246           Fn::Select:
247             - 0
248             - Fn::Select:
249               - 'ctlplane'
250               - Fn::GetAtt:
251                 - notcompute
252                 - networks
253       neutron:
254         host:
255           Fn::Select:
256             - 0
257             - Fn::Select:
258               - ctlplane
259               - Fn::GetAtt:
260                 - notcompute
261                 - networks
262         metadata_proxy_shared_secret: unset
263         ovs:
264           enable_tunneling: 'True'
265           local_ip:
266             Fn::Select:
267               - 0
268               - Fn::Select:
269                 - ctlplane
270                 - Fn::GetAtt:
271                   - notcompute
272                   - networks
273           public_interface:
274             Ref: NeutronPublicInterface
275           public_interface_raw_device:
276             Ref: NeutronPublicInterfaceRawDevice
277           public_interface_route:
278             Ref: NeutronPublicInterfaceDefaultRoute
279           physical_bridge: br-ex
280           tenant_network_type: gre
281         ovs_db: mysql://neutron:unset@localhost/ovs_neutron?charset=utf8
282         service-password:
283           Ref: NeutronPassword
284       nova:
285         compute_driver: libvirt.LibvirtDriver
286         db: mysql://nova:unset@localhost/nova
287         default_floating_pool:
288           ext-net
289         host:
290           Fn::Select:
291             - 0
292             - Fn::Select:
293               - 'ctlplane'
294               - Fn::GetAtt:
295                 - notcompute
296                 - networks
297         metadata-proxy: true
298         service-password:
299           Ref: NovaPassword
300       rabbit:
301         host:
302           Fn::Select:
303             - 0
304             - Fn::Select:
305               - ctlplane
306               - Fn::GetAtt:
307                 - notcompute
308                 - networks
309         password: guest
310   notcompute:
311     Type: OS::Nova::Server
312     Properties:
313       image:
314         Ref: notcomputeImage
315       flavor:
316         Ref: Flavor
317       key_name:
318         Ref: KeyName
319     Metadata:
320       os-collect-config:
321         cfn:
322           access_key_id:
323             Ref: Key
324           path: notcomputeConfig.Metadata
325           secret_access_key:
326             Fn::GetAtt:
327             - Key
328             - SecretAccessKey
329           stack_name:
330             Ref: AWS::StackName