Make it possible to do physical networks for VMs.
[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     NoEcho: true
15   CinderPassword:
16     Default: unset
17     Description: The password for the cinder service account, used by cinder-api.
18     Type: String
19     NoEcho: true
20   Flavor:
21     Default: baremetal
22     Description: Flavor to request when deploying.
23     Type: String
24   GlancePassword:
25     Default: unset
26     Description: The password for the glance service account, used by the glance services.
27     Type: String
28     NoEcho: true
29   HeatPassword:
30     Default: unset
31     Description: The password for the Heat service account, used by the Heat services.
32     Type: String
33     NoEcho: true
34   ImageUpdatePolicy:
35     Default: 'REPLACE'
36     Description: What policy to use when reconstructing instances. REBUILD for rebuilds, REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
37     Type: String
38   KeyName:
39     Default: default
40     Description: Name of an existing EC2 KeyPair to enable SSH access to the instances
41     Type: String
42   NeutronBridgeMappings:
43     Description: The OVS logical->physical bridge mappings to use.
44     Type: String
45     Default: ''
46   NeutronPassword:
47     Default: unset
48     Description: The password for the neutron service account, used by neutron agents.
49     Type: String
50     NoEcho: true
51   CeilometerComputeAgent:
52     Description: Indicates whether the Compute agent is present and expects nova-compute to be configured accordingly
53     Type: String
54     Default: ''
55     AllowedValues: ['', Present]
56   CeilometerMeteringSecret:
57     Default: unset
58     Description: Secret shared by the ceilometer services.
59     Type: String
60     NoEcho: true
61   CeilometerPassword:
62     Default: unset
63     Description: The password for the ceilometer service account.
64     Type: String
65     NoEcho: true
66   NovaComputeDriver:
67     Default: libvirt.LibvirtDriver
68     Type: String
69   NovaComputeLibvirtType:
70     Default: ''
71     Type: String
72   NovaImage:
73     Type: String
74     Default: overcloud-compute
75   NovaPassword:
76     Default: unset
77     Description: The password for the nova service account, used by nova-api.
78     Type: String
79     NoEcho: true
80   NeutronFlatNetworks:
81     Type: String
82     Default: ''
83     Description: If set, flat networks to configure in neutron plugins.
84   HypervisorNeutronPhysicalBridge:
85     Default: ''
86     Description: An OVS bridge to create on each hypervisor.
87     Type: String
88   HypervisorNeutronPublicInterface:
89     Default: ''
90     Description: What interface to add to the HypervisorNeutronPhysicalBridge.
91     Type: String
92   NeutronPublicInterface:
93     Default: eth0
94     Description: What interface to bridge onto br-ex for network nodes.
95     Type: String
96   NeutronPublicInterfaceDefaultRoute:
97     Default: ''
98     Description: A custom default route for the NeutronPublicInterface.
99     Type: String
100   NeutronPublicInterfaceIP:
101     Default: ''
102     Description: A custom IP address to put onto the NeutronPublicInterface.
103     Type: String
104   NeutronPublicInterfaceRawDevice:
105     Default: ''
106     Description: If set, the public interface is a vlan with this device as the raw device.
107     Type: String
108   notcomputeImage:
109     Type: String
110     Default: overcloud-control
111   NtpServer:
112     Type: String
113     Default: ''
114 Resources:
115   AccessPolicy:
116     Properties:
117       AllowedResources:
118       - notCompute0
119       - notCompute0Config
120     Type: OS::Heat::AccessPolicy
121   ComputeAccessPolicy:
122     Properties:
123       AllowedResources:
124       - NovaCompute0
125       - NovaCompute0Config
126     Type: OS::Heat::AccessPolicy
127   notCompute0Key:
128     Properties:
129       UserName:
130         Ref: User
131     Type: AWS::IAM::AccessKey
132   notCompute0CompletionCondition:
133     Type: AWS::CloudFormation::WaitCondition
134     DependsOn: notCompute0
135     Properties:
136       Handle: {Ref: notCompute0CompletionHandle}
137       Count: '1'
138       Timeout: '1800'
139   notCompute0CompletionHandle:
140     Type: OS::Heat::UpdateWaitConditionHandle
141   NovaCompute0Key:
142     Type: FileInclude
143     Path: nova-compute-instance.yaml
144     SubKey: Resources.NovaCompute0Key
145   NovaCompute0CompletionCondition:
146     Type: FileInclude
147     Path: nova-compute-instance.yaml
148     SubKey: Resources.NovaCompute0CompletionCondition
149   NovaCompute0CompletionHandle:
150     Type: FileInclude
151     Path: nova-compute-instance.yaml
152     SubKey: Resources.NovaCompute0CompletionHandle
153   ComputeUser:
154     Properties:
155       Policies:
156       - Ref: ComputeAccessPolicy
157     Type: AWS::IAM::User
158   NovaCompute0Config:
159     Type: FileInclude
160     Path: nova-compute-instance.yaml
161     SubKey: Resources.NovaCompute0Config
162     Parameters:
163         NovaApiHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ] }
164         KeystoneHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ] }
165         RabbitHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ] }
166         NeutronHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ] }
167         GlanceHost: {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ] }
168         NovaDSN: {"Fn::Join": ['', ['mysql://nova:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ]}, '/nova']]}
169         CeilometerDSN: {"Fn::Join": ['', ['mysql://ceilometer:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ]}, '/ceilometer']]}
170         NeutronDSN: {"Fn::Join": ['', ['mysql://neutron:unset@', {"Fn::Select": [ 0, {"Fn::Select": [ "ctlplane", {"Fn::GetAtt": [notCompute0, networks]} ]} ]}, '/neutron']]}
171         NeutronNetworkType: "gre"
172         NeutronEnableTunnelling: "True"
173         NeutronFlatNetworks:
174             Ref: NeutronFlatNetworks
175         NeutronNetworkVLANRanges: ""
176         NeutronPhysicalBridge:
177             Ref: HypervisorNeutronPhysicalBridge
178         NeutronPublicInterface:
179             Ref: HypervisorNeutronPublicInterface
180         NeutronBridgeMappings:
181             Ref: NeutronBridgeMappings
182         RabbitPassword: "guest"
183   NovaCompute0:
184     Type: FileInclude
185     Path: nova-compute-instance.yaml
186     SubKey: Resources.NovaCompute0
187   User:
188     Properties:
189       Policies:
190       - Ref: AccessPolicy
191     Type: AWS::IAM::User
192   notCompute0Config:
193     Type: AWS::AutoScaling::LaunchConfiguration
194     Properties:
195       ImageId: '0'
196       InstanceType: '0'
197     Metadata:
198       OpenStack::Heat::Stack: {}
199       OpenStack::ImageBuilder::Elements:
200       - boot-stack
201       - heat-cfntools
202       - heat-localip
203       - neutron-network-node
204       admin-password:
205         Ref: AdminPassword
206       admin-token:
207         Ref: AdminToken
208       bootstack:
209         public_interface_ip:
210           Ref: NeutronPublicInterfaceIP
211       cinder:
212         db: mysql://cinder:unset@localhost/cinder
213         volume_size_mb: '5000'
214         service-password:
215           Ref: CinderPassword
216       completion-handle:
217         Ref: notCompute0CompletionHandle
218       controller-address:
219         Fn::Select:
220          - 0
221          - Fn::Select:
222              - 'ctlplane'
223              - Fn::GetAtt:
224                - notCompute0
225                - networks
226       db-password: unset
227       glance:
228         backend: swift
229         db: mysql://glance:unset@localhost/glance
230         host:
231           Fn::Select:
232            - 0
233            - Fn::Select:
234                - 'ctlplane'
235                - Fn::GetAtt:
236                  - notCompute0
237                  - networks
238         service-password:
239           Ref: GlancePassword
240         swift-store-user: service:glance
241         swift-store-key:
242           Ref: GlancePassword
243       heat:
244         admin_password:
245           Ref: HeatPassword
246         admin_tenant_name: service
247         admin_user: heat
248         auth_encryption_key: unset___________
249         db: mysql://heat:unset@localhost/heat
250         watch_server_url:
251           Fn::Join:
252             - ''
253             - - 'http://'
254               - Fn::Select:
255                 - 0
256                 - Fn::Select:
257                   - 'ctlplane'
258                   - Fn::GetAtt:
259                     - notCompute0
260                     - networks
261               - ':8003'
262         metadata_server_url:
263           Fn::Join:
264             - ''
265             - - 'http://'
266               - Fn::Select:
267                 - 0
268                 - Fn::Select:
269                   - 'ctlplane'
270                   - Fn::GetAtt:
271                     - notCompute0
272                     - networks
273               - ':8000'
274         waitcondition_server_url:
275           Fn::Join:
276             - ''
277             - - 'http://'
278               - Fn::Select:
279                 - 0
280                 - Fn::Select:
281                   - 'ctlplane'
282                   - Fn::GetAtt:
283                     - notCompute0
284                     - networks
285               - ':8000/v1/waitcondition'
286       keystone:
287         db: mysql://keystone:unset@localhost/keystone
288         host:
289           Fn::Select:
290             - 0
291             - Fn::Select:
292               - 'ctlplane'
293               - Fn::GetAtt:
294                 - notCompute0
295                 - networks
296       neutron:
297         flat-networks: {Ref: NeutronFlatNetworks}
298         host:
299           Fn::Select:
300             - 0
301             - Fn::Select:
302               - ctlplane
303               - Fn::GetAtt:
304                 - notCompute0
305                 - networks
306         metadata_proxy_shared_secret: unset
307         ovs:
308           enable_tunneling: 'True'
309           local_ip:
310             Fn::Select:
311               - 0
312               - Fn::Select:
313                 - ctlplane
314                 - Fn::GetAtt:
315                   - notCompute0
316                   - networks
317           bridge_mappings: {Ref: NeutronBridgeMappings}
318           public_interface:
319             Ref: NeutronPublicInterface
320           public_interface_raw_device:
321             Ref: NeutronPublicInterfaceRawDevice
322           public_interface_route:
323             Ref: NeutronPublicInterfaceDefaultRoute
324           physical_bridge: br-ex
325           tenant_network_type: gre
326         ovs_db: mysql://neutron:unset@localhost/ovs_neutron?charset=utf8
327         service-password:
328           Ref: NeutronPassword
329       ceilometer:
330         db: mysql://ceilometer:unset@localhost/ceilometer
331         metering_secret: {Ref: CeilometerMeteringSecret}
332         service-password:
333           Ref: CeilometerPassword
334       nova:
335         compute_driver: libvirt.LibvirtDriver
336         db: mysql://nova:unset@localhost/nova
337         default_floating_pool:
338           ext-net
339         host:
340           Fn::Select:
341             - 0
342             - Fn::Select:
343               - 'ctlplane'
344               - Fn::GetAtt:
345                 - notCompute0
346                 - networks
347         metadata-proxy: true
348         service-password:
349           Ref: NovaPassword
350       os-collect-config:
351         cfn:
352           access_key_id:
353             Ref: notCompute0Key
354           path: notCompute0Config.Metadata
355           secret_access_key:
356             Fn::GetAtt:
357             - notCompute0Key
358             - SecretAccessKey
359           stack_name:
360             Ref: AWS::StackName
361       rabbit:
362         host:
363           Fn::Select:
364             - 0
365             - Fn::Select:
366               - ctlplane
367               - Fn::GetAtt:
368                 - notCompute0
369                 - networks
370         password: guest
371       ntp:
372         servers:
373             - {server: {Ref: NtpServer}, fudge: "stratum 0"}
374   notCompute0:
375     Type: OS::Nova::Server
376     Properties:
377       image:
378         Ref: notcomputeImage
379       image_update_policy:
380         Ref: ImageUpdatePolicy
381       flavor:
382         Ref: Flavor
383       key_name:
384         Ref: KeyName
385     Metadata:
386       os-collect-config:
387         cfn:
388           access_key_id:
389             Ref: notCompute0Key
390           path: notCompute0Config.Metadata
391           secret_access_key:
392             Fn::GetAtt:
393             - notCompute0Key
394             - SecretAccessKey
395           stack_name:
396             Ref: AWS::StackName
397 Outputs:
398   KeystoneURL:
399     Description: URL for the Overcloud Keystone service
400     Value:
401       Fn::Join:
402       - ''
403       - - http://
404         - Fn::Select:
405           - 0
406           - Fn::Select:
407             - ctlplane
408             - Fn::GetAtt:
409               - notCompute0
410               - networks
411         - :5000/v2.0/