1 heat_template_version: 2016-10-14
2 description: 'OpenStack {{role}} node configured by Puppet'
4 Overcloud{{role}}Flavor:
5 description: Flavor for the {{role}} node.
8 {% if disable_constraints is not defined %}
10 - custom_constraint: nova.flavor
14 default: overcloud-full
15 {% if disable_constraints is not defined %}
17 - custom_constraint: glance.image
20 default: 'REBUILD_PRESERVE_EPHEMERAL'
21 description: What policy to use when reconstructing instances. REBUILD for rebuilds, REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
24 description: Name of an existing Nova key pair to enable SSH access to the instances
27 {% if disable_constraints is not defined %}
29 - custom_constraint: nova.keypair
33 description: Mapping of service_name -> network name. Typically set
34 via parameter_defaults in the resource registry.
38 description: Mapping of service endpoint -> protocol. Typically set
39 via parameter_defaults in the resource registry.
45 Setting to a previously unused value during stack-update will trigger
46 package update on all nodes
49 default: '' # Defaults to Heat created hostname
53 description: Optional mapping to override hostnames
57 Additional hiera configuration to inject into the cluster. Note
58 that {{role}}ExtraConfig takes precedence over ExtraConfig.
63 Role specific additional hiera configuration to inject into the cluster.
68 NetworkDeploymentActions:
69 type: comma_delimited_list
71 Heat action when to apply network configuration changes
73 SoftwareConfigTransport:
74 default: POLL_SERVER_CFN
76 How the server should receive the metadata required for software configuration.
79 - allowed_values: [POLL_SERVER_CFN, POLL_SERVER_HEAT, POLL_TEMP_URL, ZAQAR_MESSAGE]
81 default: 'localdomain'
84 The DNS domain used for the hosts. This should match the dhcp_domain
85 configured in the Undercloud neutron. Defaults to localdomain.
86 {{role}}ServerMetadata:
89 Extra properties or metadata passed to Nova for the created nodes in
90 the overcloud. It's accessible via the Nova metadata API. This option is
91 role-specific and is merged with the values given to the ServerMetadata
97 Extra properties or metadata passed to Nova for the created nodes in
98 the overcloud. It's accessible via the Nova metadata API. This applies to
99 all roles and is merged with a role-specific metadata parameter.
101 {{role}}SchedulerHints:
103 description: Optional scheduler hints to pass to nova
108 ServiceConfigSettings:
112 type: comma_delimited_list
114 MonitoringSubscriptions:
115 type: comma_delimited_list
119 description: Command which will be run whenever configuration data changes
120 default: os-refresh-config --timeout 14400
125 type: comma_delimited_list
130 Command or script snippet to run on all overcloud nodes to
131 initialize the upgrade process. E.g. a repository switch.
137 type: OS::TripleO::Server
140 command: {get_param: ConfigCommand}
142 image: {get_param: {{role}}Image}
143 image_update_policy: {get_param: ImageUpdatePolicy}
144 flavor: {get_param: Overcloud{{role}}Flavor}
145 key_name: {get_param: KeyName}
148 user_data_format: SOFTWARE_CONFIG
149 user_data: {get_resource: UserData}
152 template: {get_param: Hostname}
153 params: {get_param: HostnameMap}
154 software_config_transport: {get_param: SoftwareConfigTransport}
157 - {get_param: ServerMetadata}
158 - {get_param: {{role}}ServerMetadata}
159 scheduler_hints: {get_param: {{role}}SchedulerHints}
161 # Combine the NodeAdminUserData and NodeUserData mime archives
163 type: OS::Heat::MultipartMime
166 - config: {get_resource: NodeAdminUserData}
168 - config: {get_resource: NodeUserData}
171 # Creates the "heat-admin" user if configured via the environment
172 # Should return a OS::Heat::MultipartMime reference via OS::stack_id
174 type: OS::TripleO::NodeAdminUserData
176 # For optional operator additional userdata
177 # Should return a OS::Heat::MultipartMime reference via OS::stack_id
179 type: OS::TripleO::NodeUserData
182 type: OS::TripleO::{{role}}::Ports::ExternalPort
184 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
185 IPPool: {get_param: {{role}}IPs}
186 NodeIndex: {get_param: NodeIndex}
189 type: OS::TripleO::{{role}}::Ports::InternalApiPort
191 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
192 IPPool: {get_param: {{role}}IPs}
193 NodeIndex: {get_param: NodeIndex}
196 type: OS::TripleO::{{role}}::Ports::StoragePort
198 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
199 IPPool: {get_param: {{role}}IPs}
200 NodeIndex: {get_param: NodeIndex}
203 type: OS::TripleO::{{role}}::Ports::StorageMgmtPort
205 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
206 IPPool: {get_param: {{role}}IPs}
207 NodeIndex: {get_param: NodeIndex}
210 type: OS::TripleO::{{role}}::Ports::TenantPort
212 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
213 IPPool: {get_param: {{role}}IPs}
214 NodeIndex: {get_param: NodeIndex}
217 type: OS::TripleO::{{role}}::Ports::ManagementPort
219 ControlPlaneIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
220 IPPool: {get_param: {{role}}IPs}
221 NodeIndex: {get_param: NodeIndex}
224 type: OS::TripleO::{{role}}::Net::SoftwareConfig
226 ControlPlaneIp: {get_attr: [{{role}}, networks, ctlplane, 0]}
227 ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
228 InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
229 StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
230 StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
231 TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
232 ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
235 type: OS::TripleO::Network::Ports::NetIpMap
237 ControlPlaneIp: {get_attr: [{{role}}, networks, ctlplane, 0]}
238 ExternalIp: {get_attr: [ExternalPort, ip_address]}
239 ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
240 ExternalIpUri: {get_attr: [ExternalPort, ip_address_uri]}
241 InternalApiIp: {get_attr: [InternalApiPort, ip_address]}
242 InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
243 InternalApiIpUri: {get_attr: [InternalApiPort, ip_address_uri]}
244 StorageIp: {get_attr: [StoragePort, ip_address]}
245 StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
246 StorageIpUri: {get_attr: [StoragePort, ip_address_uri]}
247 StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
248 StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
249 StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
250 TenantIp: {get_attr: [TenantPort, ip_address]}
251 TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
252 TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
253 ManagementIp: {get_attr: [ManagementPort, ip_address]}
254 ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
255 ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
258 type: OS::Heat::Value
266 - - {get_attr: [{{role}}, name]}
268 - {get_param: CloudDomain}
272 - - {get_attr: [{{role}}, name]}
278 - - {get_attr: [{{role}}, name]}
280 - {get_param: CloudDomain}
284 - - {get_attr: [{{role}}, name]}
290 - - {get_attr: [{{role}}, name]}
292 - {get_param: CloudDomain}
296 - - {get_attr: [{{role}}, name]}
302 - - {get_attr: [{{role}}, name]}
304 - {get_param: CloudDomain}
308 - - {get_attr: [{{role}}, name]}
314 - - {get_attr: [{{role}}, name]}
316 - {get_param: CloudDomain}
320 - - {get_attr: [{{role}}, name]}
326 - - {get_attr: [{{role}}, name]}
328 - {get_param: CloudDomain}
332 - - {get_attr: [{{role}}, name]}
338 - - {get_attr: [{{role}}, name]}
340 - {get_param: CloudDomain}
344 - - {get_attr: [{{role}}, name]}
348 type: OS::TripleO::SoftwareDeployment
350 name: NetworkDeployment
351 config: {get_resource: NetworkConfig}
352 server: {get_resource: {{role}}}
353 actions: {get_param: NetworkDeploymentActions}
355 {{role}}UpgradeInitConfig:
356 type: OS::Heat::SoftwareConfig
362 - - "#!/bin/bash\n\n"
363 - "if [[ -f /etc/resolv.conf.save ]] ; then rm /etc/resolv.conf.save; fi\n\n"
364 - get_param: UpgradeInitCommand
366 # Note we may be able to make this conditional on UpgradeInitCommandNotEmpty
367 # but https://bugs.launchpad.net/heat/+bug/1649900 needs fixing first
368 {{role}}UpgradeInitDeployment:
369 type: OS::Heat::SoftwareDeployment
370 depends_on: NetworkDeployment
372 name: {{role}}UpgradeInitDeployment
373 server: {get_resource: {{role}}}
374 config: {get_resource: {{role}}UpgradeInitConfig}
377 type: OS::Heat::StructuredDeployment
378 depends_on: {{role}}UpgradeInitDeployment
380 name: {{role}}Deployment
381 config: {get_resource: {{role}}Config}
382 server: {get_resource: {{role}}}
384 enable_package_upgrade: {get_attr: [UpdateDeployment, update_managed_packages]}
387 type: OS::Heat::StructuredConfig
393 - heat_config_%{::deploy_config_name}
394 - {{role.lower()}}_extraconfig
399 - bootstrap_node # provided by allNodesConfig
400 - all_nodes # provided by allNodesConfig
401 - vip_data # provided by allNodesConfig
403 merge_behavior: deeper
406 service_names: {get_param: ServiceNames}
407 sensu::subscriptions: {get_param: MonitoringSubscriptions}
410 - {get_param: ServiceConfigSettings}
411 - values: {get_attr: [NetIpMap, net_ip_map]}
412 {{role.lower()}}_extraconfig: {get_param: {{role}}ExtraConfig}
413 extraconfig: {get_param: ExtraConfig}
415 tripleo::packages::enable_upgrade: {get_input: enable_package_upgrade}
416 tripleo::profile::base::logging::fluentd::fluentd_sources: {get_param: LoggingSources}
417 tripleo::profile::base::logging::fluentd::fluentd_groups: {get_param: LoggingGroups}
418 fqdn_internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
419 fqdn_storage: {get_attr: [NetHostMap, value, storage, fqdn]}
420 fqdn_storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
421 fqdn_tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
422 fqdn_management: {get_attr: [NetHostMap, value, management, fqdn]}
423 fqdn_ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
425 # Resource for site-specific injection of root certificate
427 depends_on: {{role}}Deployment
428 type: OS::TripleO::NodeTLSCAData
430 server: {get_resource: {{role}}}
432 # Hook for site-specific additional pre-deployment config, e.g extra hieradata
433 {{role}}ExtraConfigPre:
434 depends_on: {{role}}Deployment
435 type: OS::TripleO::{{role}}ExtraConfigPre
437 server: {get_resource: {{role}}}
439 # Hook for site-specific additional pre-deployment config,
440 # applying to all nodes, e.g node registration/unregistration
442 depends_on: [{{role}}ExtraConfigPre, NodeTLSCAData]
443 type: OS::TripleO::NodeExtraConfig
445 server: {get_resource: {{role}}}
448 type: OS::TripleO::Tasks::PackageUpdate
451 type: OS::Heat::SoftwareDeployment
453 config: {get_resource: UpdateConfig}
454 server: {get_resource: {{role}}}
457 get_param: UpdateIdentifier
461 description: IP address of the server in the ctlplane network
462 value: {get_attr: [{{role}}, networks, ctlplane, 0]}
464 description: Hostname of the server
465 value: {get_attr: [{{role}}, name]}
467 description: Mapping of network names to hostnames
469 external: {get_attr: [NetHostMap, value, external, fqdn]}
470 internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
471 storage: {get_attr: [NetHostMap, value, storage, fqdn]}
472 storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
473 tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
474 management: {get_attr: [NetHostMap, value, management, fqdn]}
475 ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
480 PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST
481 EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST
482 INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST
483 STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST
484 STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST
485 TENANTIP TENANTHOST.DOMAIN TENANTHOST
486 MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST
487 CTLPLANEIP CTLPLANEHOST.DOMAIN CTLPLANEHOST
489 PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, {{role}}HostnameResolveNetwork]}]}
490 DOMAIN: {get_param: CloudDomain}
491 PRIMARYHOST: {get_attr: [{{role}}, name]}
492 EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
493 EXTERNALHOST: {get_attr: [NetHostMap, value, external, short]}
494 INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
495 INTERNAL_APIHOST: {get_attr: [NetHostMap, value, internal_api, short]}
496 STORAGEIP: {get_attr: [StoragePort, ip_address]}
497 STORAGEHOST: {get_attr: [NetHostMap, value, storage, short]}
498 STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
499 STORAGE_MGMTHOST: {get_attr: [NetHostMap, value, storage_mgmt, short]}
500 TENANTIP: {get_attr: [TenantPort, ip_address]}
501 TENANTHOST: {get_attr: [NetHostMap, value, tenant, short]}
502 MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
503 MANAGEMENTHOST: {get_attr: [NetHostMap, value, management, short]}
504 CTLPLANEIP: {get_attr: [{{role}}, networks, ctlplane, 0]}
505 CTLPLANEHOST: {get_attr: [NetHostMap, value, ctlplane, short]}
506 nova_server_resource:
507 description: Heat resource handle for {{role}} server
509 {get_resource: {{role}}}
511 description: IP address of the server in the external network
512 value: {get_attr: [ExternalPort, ip_address]}
513 internal_api_ip_address:
514 description: IP address of the server in the internal_api network
515 value: {get_attr: [InternalApiPort, ip_address]}
517 description: IP address of the server in the storage network
518 value: {get_attr: [StoragePort, ip_address]}
519 storage_mgmt_ip_address:
520 description: IP address of the server in the storage_mgmt network
521 value: {get_attr: [StorageMgmtPort, ip_address]}
523 description: IP address of the server in the tenant network
524 value: {get_attr: [TenantPort, ip_address]}
525 management_ip_address:
526 description: IP address of the server in the management network
527 value: {get_attr: [ManagementPort, ip_address]}