be743ce391aadb82e933dbd6381611aa13fd33f1
[apex-tripleo-heat-templates.git] / undercloud-source.yaml
1 description: All-in-one baremetal OpenStack and all dependencies.
2 heat_template_version: 2014-10-16
3 parameters:
4   AdminPassword:
5     default: unset
6     description: The password for the keystone admin account, used for monitoring, querying neutron etc.
7     type: string
8     hidden: true
9   AdminToken:
10     default: unset
11     description: The keystone auth secret.
12     type: string
13     hidden: true
14   CinderLVMLoopDeviceSize:
15     default: 5000
16     description: The size of the loopback file used by the cinder LVM driver.
17     type: number
18   BaremetalArch:
19     default: i386
20     description: The architecture to use in Nova-BM - i386 or amd64.
21     type: string
22   CeilometerMeteringSecret:
23     default: unset
24     description: Secret shared by the ceilometer services.
25     type: string
26     hidden: true
27   CeilometerPassword:
28     default: unset
29     description: The password for the ceilometer service account.
30     type: string
31     hidden: true
32   SnmpdReadonlyUserName:
33     default: ro_snmp_user
34     description: The user name for SNMPd with readonly rights running on all Overcloud nodes
35     type: string
36   SnmpdReadonlyUserPassword:
37     default: unset
38     description: The user password for SNMPd with readonly rights running on all Overcloud nodes
39     type: string
40     hidden: true
41   ExtraConfig:
42     default: {}
43     description: |
44       Additional configuration to inject into the cluster. The JSON should have
45       the following structure:
46         {"FILEKEY":
47           {"config:
48             [{"section": "SECTIONNAME",
49               "values":
50                [{"option": "OPTIONNAME",
51                   "value": "VALUENAME"
52                 }
53                ]
54              }
55             ]
56           }
57         }
58       For instance:
59         {"nova":
60           {"config":
61             [{"section": "default",
62               "values":
63                 [{"option": "compute_manager",
64                   "value": "ironic.nova.compute.manager.ClusterComputeManager"
65                  }
66                 ]
67              },
68              {"section": "cells",
69               "values":
70                 [{"option": "driver",
71                   "value": "nova.cells.rpc_driver.CellsRPCDriver"
72                  }
73                 ]
74              }
75             ]
76           }
77         }
78     type: json
79   Flavor:
80     default: baremetal
81     description: Flavor to request when deploying.
82     type: string
83   GlancePort:
84    default: 9292
85    description: Glance port.
86    type: string
87   GlanceProtocol:
88    default: http
89    description: Protocol to use when connecting to glance, set to https for SSL.
90    type: string
91   GlancePassword:
92     default: unset
93     description: The password for the glance service account, used by the glance services.
94     type: string
95     hidden: true
96   GlanceNotifierStrategy:
97     description: Strategy to use for Glance notification queue
98     type: string
99     default: noop
100   GlanceLogFile:
101     description: The filepath of the file to use for logging messages from Glance.
102     type: string
103     default: ''
104   KeyName:
105     default: default
106     description: Name of an existing EC2 KeyPair to enable SSH access to the instances
107     type: string
108   HeatPassword:
109     default: unset
110     description: The password for the Heat service account, used by the Heat services.
111     type: string
112     hidden: true
113   ImageUpdatePolicy:
114     default: REBUILD_PRESERVE_EPHEMERAL
115     description: What policy to use when reconstructing instances. REBUILD for rebuilds,
116       REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
117     type: string
118   undercloudImage:
119     default: undercloud
120     type: string
121   NeutronPassword:
122     default: unset
123     description: The password for the neutron service account, used by neutron agents.
124     type: string
125     hidden: true
126   NovaPassword:
127     default: unset
128     description: The password for the nova service account, used by nova-api.
129     type: string
130     hidden: true
131   NeutronPublicInterfaceDefaultRoute:
132     default: ''
133     description: A custom default route for the NeutronPublicInterface.
134     type: string
135   NeutronPublicInterfaceIP:
136     default: ''
137     description: A custom IP address to put onto the NeutronPublicInterface.
138     type: string
139   NeutronPublicInterfaceRawDevice:
140     default: ''
141     description: If set, the public interface is a vlan with this device as the raw device.
142     type: string
143   NtpServer:
144     type: string
145     default: ''
146   RabbitUserName:
147     default: guest
148     description: The username for RabbitMQ
149     type: string
150   RabbitPassword:
151     default: guest
152     description: The password for RabbitMQ
153     type: string
154     hidden: true
155   RabbitCookieSalt:
156     type: string
157     default: unset
158     description: Salt for the rabbit cookie, change this to force the randomly generated rabbit cookie to change.
159   HeatStackDomainAdminPassword:
160     description: Password for heat_domain_admin user.
161     type: string
162     default: ''
163     hidden: true
164   MysqlInnodbBufferPoolSize:
165     description: >
166         Specifies the size of the buffer pool in megabytes. Setting to
167         zero should be interpreted as "no value" and will defer to the
168         lower level default.
169     type: number
170     default: 0
171   KeystoneCACertificate:
172     default: ''
173     description: Keystone self-signed certificate authority certificate.
174     type: string
175   KeystoneSigningCertificate:
176     default: ''
177     description: Keystone certificate for verifying token validity.
178     type: string
179   KeystoneSigningKey:
180     default: ''
181     description: Keystone key for signing tokens.
182     type: string
183     hidden: true
184 resources:
185   RabbitCookie:
186     type: OS::Heat::RandomString
187     properties:
188       length: 20
189       salt:
190         get_param: RabbitCookieSalt
191   undercloudConfig:
192     type: OS::Heat::StructuredConfig
193     properties:
194       config:
195         completion-signal: {get_input: deploy_signal_id}
196         admin-password:
197           get_param: AdminPassword
198         admin-token:
199           get_param: AdminToken
200         bootstrap_host:
201           bootstrap_nodeid: {get_attr: [undercloud, show, name]}
202           nodeid: {get_input: bootstack_nodeid}
203         bootstack:
204           public_interface_ip:
205             get_param: NeutronPublicInterfaceIP
206         controller-address:
207           get_input: controller_host
208         ceilometer:
209           db: mysql://ceilometer:unset@localhost/ceilometer
210           metering_secret: {get_param: CeilometerMeteringSecret}
211           snmpd_readonly_user_name:
212             get_param: SnmpdReadonlyUserName
213           snmpd_readonly_user_password:
214             get_param: SnmpdReadonlyUserPassword
215           service-password:
216             get_param: CeilometerPassword
217         db-password: unset
218         glance:
219           backend: file
220           db: mysql://glance:unset@localhost/glance
221           host: 127.0.0.1
222           port:
223             get_param: GlancePort
224           protocol:
225             get_param: GlanceProtocol
226           service-password:
227             get_param: GlancePassword
228           notifier-strategy:
229             get_param: GlanceNotifierStrategy
230           log-file:
231             get_param: GlanceLogFile
232         heat:
233           admin_password:
234             get_param: HeatPassword
235           admin_tenant_name: service
236           admin_user: heat
237           auth_encryption_key: unset___________
238           db: mysql://heat:unset@localhost/heat
239           stack_domain_admin_password: {get_param: HeatStackDomainAdminPassword}
240           watch_server_url: {get_input: heat.watch_server_url}
241           metadata_server_url: {get_input: heat.metadata_server_url}
242           waitcondition_server_url: {get_input: heat.waitcondition_server_url}
243         keystone:
244           db: mysql://keystone:unset@localhost/keystone
245           host: 127.0.0.1
246           ca_certificate: {get_param: KeystoneCACertificate}
247           signing_key: {get_param: KeystoneSigningKey}
248           signing_certificate: {get_param: KeystoneSigningCertificate}
249         mysql:
250           innodb_buffer_pool_size: {get_param: MysqlInnodbBufferPoolSize}
251         neutron:
252           host: 127.0.0.1
253           ovs_db: mysql://neutron:unset@localhost/ovs_neutron?charset=utf8
254           ovs:
255             public_interface:
256               get_param: NeutronPublicInterface
257             public_interface_raw_device:
258               get_param: NeutronPublicInterfaceRawDevice
259             public_interface_route:
260               get_param: NeutronPublicInterfaceDefaultRoute
261             physical_bridge: br-ctlplane
262             physical_network: ctlplane
263             network_vlan_ranges: ctlplane
264             bridge_mappings: ctlplane:br-ctlplane
265             tenant_network_type: vlan
266             enable_tunneling: 'False'
267           service-password:
268             get_param: NeutronPassword
269         rabbit:
270           host: 127.0.0.1
271           username:
272             get_param: RabbitUserName
273           password:
274             get_param: RabbitPassword
275           cookie:
276             get_attr:
277             - RabbitCookie
278             - value
279         ntp:
280           servers:
281             - {server: {get_param: NtpServer}, fudge: "stratum 0"}
282   undercloudPassthroughConfig:
283     type: OS::Heat::StructuredConfig
284     properties:
285       config: {get_input: passthrough_config}
286   undercloud:
287     type: OS::Nova::Server
288     properties:
289       image:
290         get_param: undercloudImage
291       flavor:
292         get_param: Flavor
293       key_name:
294         get_param: KeyName
295       image_update_policy:
296         get_param: ImageUpdatePolicy
297       networks:
298         - network: ctlplane
299       user_data_format: SOFTWARE_CONFIG
300   99_undercloudDeployment:
301     type: OS::Heat::StructuredDeployment
302     properties:
303       config: {get_resource: undercloudConfig}
304       server: {get_resource: undercloud}
305       input_values:
306         bootstack_nodeid:
307           get_attr:
308           - undercloud
309           - show
310           - name
311         controller_host:
312           get_attr:
313           - undercloud
314           - networks
315           - ctlplane
316           - 0
317         heat.watch_server_url:
318           list_join:
319             - ''
320             - - 'http://'
321               - get_attr: [undercloud, networks, ctlplane, 0]
322               - ':8003'
323         heat.metadata_server_url:
324           list_join:
325             - ''
326             - - 'http://'
327               - {get_attr: [undercloud, networks, ctlplane, 0]}
328               - ':8000'
329         heat.waitcondition_server_url:
330           list_join:
331             - ''
332             - - 'http://'
333               - {get_attr: [undercloud, networks, ctlplane, 0]}
334               - ':8000/v1/waitcondition'
335   00_undercloudPassthroughDeployment:
336     type: OS::Heat::StructuredDeployment
337     properties:
338       config: {get_resource: undercloudPassthroughConfig}
339       server: {get_resource: undercloud}
340       signal_transport: NO_SIGNAL
341       input_values:
342         passthrough_config: {get_param: ExtraConfig}