1 heat_template_version: pike
2 description: 'OpenStack ceph storage node configured by Puppet'
4 OvercloudCephStorageFlavor:
5 description: Flavor for the Ceph Storage node.
9 - custom_constraint: nova.flavor
12 default: overcloud-full
14 - custom_constraint: glance.image
16 default: 'REBUILD_PRESERVE_EPHEMERAL'
17 description: What policy to use when reconstructing instances. REBUILD for rebuilds, REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
20 description: Name of an existing Nova key pair to enable SSH access to the instances
24 - custom_constraint: nova.keypair
27 description: Mapping of service_name -> network name. Typically set
28 via parameter_defaults in the resource registry.
32 description: Mapping of service endpoint -> protocol. Typically set
33 via parameter_defaults in the resource registry.
39 Setting to a previously unused value during stack-update will trigger
40 package update on all nodes
43 default: '' # Defaults to Heat created hostname
47 description: Optional mapping to override hostnames
51 Additional hiera configuration to inject into the cluster. Note
52 that CephStorageExtraConfig takes precedence over ExtraConfig.
54 CephStorageExtraConfig:
57 Role specific additional hiera configuration to inject into the cluster.
62 NetworkDeploymentActions:
63 type: comma_delimited_list
65 Heat action when to apply network configuration changes
67 SoftwareConfigTransport:
68 default: POLL_SERVER_CFN
70 How the server should receive the metadata required for software configuration.
73 - allowed_values: [POLL_SERVER_CFN, POLL_SERVER_HEAT, POLL_TEMP_URL, ZAQAR_MESSAGE]
75 default: 'localdomain'
78 The DNS domain used for the hosts. This must match the
79 overcloud_domain_name configured on the undercloud.
80 CephStorageServerMetadata:
83 Extra properties or metadata passed to Nova for the created nodes in
84 the overcloud. It's accessible via the Nova metadata API. This option is
85 role-specific and is merged with the values given to the ServerMetadata
91 Extra properties or metadata passed to Nova for the created nodes in
92 the overcloud. It's accessible via the Nova metadata API. This applies to
93 all roles and is merged with a role-specific metadata parameter.
95 CephStorageSchedulerHints:
97 description: Optional scheduler hints to pass to nova
102 ServiceConfigSettings:
106 type: comma_delimited_list
108 MonitoringSubscriptions:
109 type: comma_delimited_list
111 ServiceMetadataSettings:
116 description: Command which will be run whenever configuration data changes
117 default: os-refresh-config --timeout 14400
122 Maximum amount of time to possibly to delay configuation collection
123 polling. Defaults to 30 seconds. Set to 0 to disable it which will cause
124 the configuration collection to occur as soon as the collection process
125 starts. This setting is used to prevent the configuration collection
126 processes from polling all at the exact same time.
130 Command or script snippet to run on all overcloud nodes to
131 initialize the upgrade process. E.g. a repository switch.
133 UpgradeInitCommonCommand:
136 Common commands required by the upgrades process. This should not
137 normally be modified by the operator and is set and unset in the
138 major-upgrade-composable-steps.yaml and major-upgrade-converge.yaml
141 DeploymentServerBlacklistDict:
145 Map of server hostnames to blacklist from any triggered
146 deployments. If the value is 1, the server will be blacklisted. This
147 parameter is generated from the parent template.
150 description: Role Specific Parameters
154 server_not_blacklisted:
157 - {get_param: [DeploymentServerBlacklistDict, {get_param: Hostname}]}
162 type: OS::TripleO::CephStorageServer
165 command: {get_param: ConfigCommand}
166 splay: {get_param: ConfigCollectSplay}
168 image: {get_param: CephStorageImage}
169 image_update_policy: {get_param: ImageUpdatePolicy}
170 flavor: {get_param: OvercloudCephStorageFlavor}
171 key_name: {get_param: KeyName}
174 user_data_format: SOFTWARE_CONFIG
175 user_data: {get_resource: UserData}
178 template: {get_param: Hostname}
179 params: {get_param: HostnameMap}
180 software_config_transport: {get_param: SoftwareConfigTransport}
183 - {get_param: ServerMetadata}
184 - {get_param: CephStorageServerMetadata}
185 - {get_param: ServiceMetadataSettings}
186 scheduler_hints: {get_param: CephStorageSchedulerHints}
188 # Combine the NodeAdminUserData and NodeUserData mime archives
190 type: OS::Heat::MultipartMime
193 - config: {get_resource: NodeAdminUserData}
195 - config: {get_resource: NodeUserData}
197 - config: {get_resource: RoleUserData}
200 # Creates the "heat-admin" user if configured via the environment
201 # Should return a OS::Heat::MultipartMime reference via OS::stack_id
203 type: OS::TripleO::NodeAdminUserData
205 # For optional operator additional userdata
206 # Should return a OS::Heat::MultipartMime reference via OS::stack_id
208 type: OS::TripleO::NodeUserData
210 # For optional operator role-specific userdata
211 # Should return a OS::Heat::MultipartMime reference via OS::stack_id
213 type: OS::TripleO::CephStorage::NodeUserData
216 type: OS::TripleO::CephStorage::Ports::ExternalPort
218 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
219 IPPool: {get_param: CephStorageIPs}
220 NodeIndex: {get_param: NodeIndex}
223 type: OS::TripleO::CephStorage::Ports::InternalApiPort
225 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
226 IPPool: {get_param: CephStorageIPs}
227 NodeIndex: {get_param: NodeIndex}
230 type: OS::TripleO::CephStorage::Ports::StoragePort
232 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
233 IPPool: {get_param: CephStorageIPs}
234 NodeIndex: {get_param: NodeIndex}
237 type: OS::TripleO::CephStorage::Ports::StorageMgmtPort
239 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
240 IPPool: {get_param: CephStorageIPs}
241 NodeIndex: {get_param: NodeIndex}
244 type: OS::TripleO::CephStorage::Ports::TenantPort
246 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
247 IPPool: {get_param: CephStorageIPs}
248 NodeIndex: {get_param: NodeIndex}
251 type: OS::TripleO::CephStorage::Ports::ManagementPort
253 ControlPlaneIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
254 IPPool: {get_param: CephStorageIPs}
255 NodeIndex: {get_param: NodeIndex}
258 type: OS::TripleO::CephStorage::Net::SoftwareConfig
260 ControlPlaneIp: {get_attr: [CephStorage, networks, ctlplane, 0]}
261 ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
262 InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
263 StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
264 StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
265 TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
266 ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
269 type: OS::TripleO::Network::Ports::NetIpMap
271 ControlPlaneIp: {get_attr: [CephStorage, networks, ctlplane, 0]}
272 ExternalIp: {get_attr: [ExternalPort, ip_address]}
273 ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
274 ExternalIpUri: {get_attr: [ExternalPort, ip_address_uri]}
275 InternalApiIp: {get_attr: [InternalApiPort, ip_address]}
276 InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
277 InternalApiIpUri: {get_attr: [InternalApiPort, ip_address_uri]}
278 StorageIp: {get_attr: [StoragePort, ip_address]}
279 StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
280 StorageIpUri: {get_attr: [StoragePort, ip_address_uri]}
281 StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
282 StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
283 StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
284 TenantIp: {get_attr: [TenantPort, ip_address]}
285 TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
286 TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
287 ManagementIp: {get_attr: [ManagementPort, ip_address]}
288 ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
289 ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
292 type: OS::Heat::Value
300 - - {get_attr: [CephStorage, name]}
302 - {get_param: CloudDomain}
306 - - {get_attr: [CephStorage, name]}
312 - - {get_attr: [CephStorage, name]}
314 - {get_param: CloudDomain}
318 - - {get_attr: [CephStorage, name]}
324 - - {get_attr: [CephStorage, name]}
326 - {get_param: CloudDomain}
330 - - {get_attr: [CephStorage, name]}
336 - - {get_attr: [CephStorage, name]}
338 - {get_param: CloudDomain}
342 - - {get_attr: [CephStorage, name]}
348 - - {get_attr: [CephStorage, name]}
350 - {get_param: CloudDomain}
354 - - {get_attr: [CephStorage, name]}
360 - - {get_attr: [CephStorage, name]}
362 - {get_param: CloudDomain}
366 - - {get_attr: [CephStorage, name]}
372 - - {get_attr: [CephStorage, name]}
374 - {get_param: CloudDomain}
378 - - {get_attr: [CephStorage, name]}
382 type: OS::TripleO::CephStorage::PreNetworkConfig
384 server: {get_resource: CephStorage}
385 RoleParameters: {get_param: RoleParameters}
386 deployment_actions: {get_attr: [DeploymentActions, value]}
389 type: OS::TripleO::SoftwareDeployment
390 depends_on: PreNetworkConfig
392 name: NetworkDeployment
393 config: {get_resource: NetworkConfig}
394 server: {get_resource: CephStorage}
397 - server_not_blacklisted
398 - {get_param: NetworkDeploymentActions}
401 CephStorageUpgradeInitConfig:
402 type: OS::Heat::SoftwareConfig
408 - - "#!/bin/bash\n\n"
409 - "if [[ -f /etc/resolv.conf.save ]] ; then rm /etc/resolv.conf.save; fi\n\n"
410 - get_param: UpgradeInitCommand
411 - get_param: UpgradeInitCommonCommand
413 # Note we may be able to make this conditional on UpgradeInitCommandNotEmpty
414 # but https://bugs.launchpad.net/heat/+bug/1649900 needs fixing first
415 CephStorageUpgradeInitDeployment:
416 type: OS::Heat::SoftwareDeployment
417 depends_on: NetworkDeployment
419 name: CephStorageUpgradeInitDeployment
420 server: {get_resource: CephStorage}
421 config: {get_resource: CephStorageUpgradeInitConfig}
424 - server_not_blacklisted
425 - ['CREATE', 'UPDATE']
428 CephStorageDeployment:
429 type: OS::Heat::StructuredDeployment
430 depends_on: CephStorageUpgradeInitDeployment
432 name: CephStorageDeployment
433 config: {get_resource: CephStorageConfig}
434 server: {get_resource: CephStorage}
436 enable_package_upgrade: {get_attr: [UpdateDeployment, update_managed_packages]}
439 - server_not_blacklisted
440 - ['CREATE', 'UPDATE']
444 type: OS::Heat::StructuredConfig
450 - heat_config_%{::deploy_config_name}
457 - bootstrap_node # provided by allNodesConfig
458 - all_nodes # provided by allNodesConfig
459 - vip_data # provided by allNodesConfig
461 merge_behavior: deeper
464 service_names: {get_param: ServiceNames}
465 sensu::subscriptions: {get_param: MonitoringSubscriptions}
468 - {get_param: ServiceConfigSettings}
469 - values: {get_attr: [NetIpMap, net_ip_map]}
470 ceph_extraconfig: {get_param: CephStorageExtraConfig}
471 extraconfig: {get_param: ExtraConfig}
473 tripleo::packages::enable_upgrade: {get_input: enable_package_upgrade}
474 fqdn_internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
475 fqdn_storage: {get_attr: [NetHostMap, value, storage, fqdn]}
476 fqdn_storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
477 fqdn_tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
478 fqdn_management: {get_attr: [NetHostMap, value, management, fqdn]}
479 fqdn_ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
480 fqdn_external: {get_attr: [NetHostMap, value, external, fqdn]}
482 # Resource for site-specific injection of root certificate
484 depends_on: CephStorageDeployment
485 type: OS::TripleO::NodeTLSCAData
487 server: {get_resource: CephStorage}
489 # Hook for site-specific additional pre-deployment config, e.g extra hieradata
490 CephStorageExtraConfigPre:
491 depends_on: CephStorageDeployment
492 type: OS::TripleO::CephStorageExtraConfigPre
493 # We have to use conditions here so that we don't break backwards
494 # compatibility with templates everywhere
495 condition: server_not_blacklisted
497 server: {get_resource: CephStorage}
499 # Hook for site-specific additional pre-deployment config,
500 # applying to all nodes, e.g node registration/unregistration
502 depends_on: [CephStorageExtraConfigPre, NodeTLSCAData]
503 type: OS::TripleO::NodeExtraConfig
504 # We have to use conditions here so that we don't break backwards
505 # compatibility with templates everywhere
506 condition: server_not_blacklisted
508 server: {get_resource: CephStorage}
511 type: OS::TripleO::Tasks::PackageUpdate
514 type: OS::Heat::SoftwareDeployment
515 depends_on: NetworkDeployment
517 config: {get_resource: UpdateConfig}
518 server: {get_resource: CephStorage}
521 get_param: UpdateIdentifier
524 - server_not_blacklisted
525 - ['CREATE', 'UPDATE']
529 type: OS::Heat::Value
533 - server_not_blacklisted
534 - ['CREATE', 'UPDATE']
538 type: OS::TripleO::Ssh::HostPubKey
539 depends_on: CephStorageDeployment
541 server: {get_resource: CephStorage}
542 deployment_actions: {get_attr: [DeploymentActions, value]}
546 description: IP address of the server in the ctlplane network
547 value: {get_attr: [CephStorage, networks, ctlplane, 0]}
549 description: Hostname of the server
550 value: {get_attr: [CephStorage, name]}
552 description: Mapping of network names to hostnames
554 external: {get_attr: [NetHostMap, value, external, fqdn]}
555 internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
556 storage: {get_attr: [NetHostMap, value, storage, fqdn]}
557 storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
558 tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
559 management: {get_attr: [NetHostMap, value, management, fqdn]}
560 ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
565 PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST
566 EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST
567 INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST
568 STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST
569 STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST
570 TENANTIP TENANTHOST.DOMAIN TENANTHOST
571 MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST
572 CTLPLANEIP CTLPLANEHOST.DOMAIN CTLPLANEHOST
574 PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CephStorageHostnameResolveNetwork]}]}
575 DOMAIN: {get_param: CloudDomain}
576 PRIMARYHOST: {get_attr: [CephStorage, name]}
577 EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
578 EXTERNALHOST: {get_attr: [NetHostMap, value, external, short]}
579 INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
580 INTERNAL_APIHOST: {get_attr: [NetHostMap, value, internal_api, short]}
581 STORAGEIP: {get_attr: [StoragePort, ip_address]}
582 STORAGEHOST: {get_attr: [NetHostMap, value, storage, short]}
583 STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
584 STORAGE_MGMTHOST: {get_attr: [NetHostMap, value, storage_mgmt, short]}
585 TENANTIP: {get_attr: [TenantPort, ip_address]}
586 TENANTHOST: {get_attr: [NetHostMap, value, tenant, short]}
587 MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
588 MANAGEMENTHOST: {get_attr: [NetHostMap, value, management, short]}
589 CTLPLANEIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
590 CTLPLANEHOST: {get_attr: [NetHostMap, value, ctlplane, short]}
592 description: Entry for ssh known hosts
595 template: "PRIMARYIP,PRIMARYHOST.DOMAIN,PRIMARYHOST,\
596 EXTERNALIP,EXTERNALHOST.DOMAIN,EXTERNALHOST,\
597 INTERNAL_APIIP,INTERNAL_APIHOST.DOMAIN,INTERNAL_APIHOST,\
598 STORAGEIP,STORAGEHOST.DOMAIN,STORAGEHOST,\
599 STORAGE_MGMTIP,STORAGE_MGMTHOST.DOMAIN,STORAGE_MGMTHOST,\
600 TENANTIP,TENANTHOST.DOMAIN,TENANTHOST,\
601 MANAGEMENTIP,MANAGEMENTHOST.DOMAIN,MANAGEMENTHOST,\
602 CTLPLANEIP,CTLPLANEHOST.DOMAIN,CTLPLANEHOST HOSTSSHPUBKEY"
604 PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CephStorageHostnameResolveNetwork]}]}
605 DOMAIN: {get_param: CloudDomain}
606 PRIMARYHOST: {get_attr: [CephStorage, name]}
607 EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
608 EXTERNALHOST: {get_attr: [NetHostMap, value, external, short]}
609 INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
610 INTERNAL_APIHOST: {get_attr: [NetHostMap, value, internal_api, short]}
611 STORAGEIP: {get_attr: [StoragePort, ip_address]}
612 STORAGEHOST: {get_attr: [NetHostMap, value, storage, short]}
613 STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
614 STORAGE_MGMTHOST: {get_attr: [NetHostMap, value, storage_mgmt, short]}
615 TENANTIP: {get_attr: [TenantPort, ip_address]}
616 TENANTHOST: {get_attr: [NetHostMap, value, tenant, short]}
617 MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
618 MANAGEMENTHOST: {get_attr: [NetHostMap, value, management, short]}
619 CTLPLANEIP: {get_attr: [CephStorage, networks, ctlplane, 0]}
620 CTLPLANEHOST: {get_attr: [NetHostMap, value, ctlplane, short]}
621 HOSTSSHPUBKEY: {get_attr: [SshHostPubKey, ecdsa]}
622 nova_server_resource:
623 description: Heat resource handle for the ceph storage server
625 {get_resource: CephStorage}
626 condition: server_not_blacklisted
628 description: IP address of the server in the external network
629 value: {get_attr: [ExternalPort, ip_address]}
630 internal_api_ip_address:
631 description: IP address of the server in the internal_api network
632 value: {get_attr: [InternalApiPort, ip_address]}
634 description: IP address of the server in the storage network
635 value: {get_attr: [StoragePort, ip_address]}
636 storage_mgmt_ip_address:
637 description: IP address of the server in the storage_mgmt network
638 value: {get_attr: [StorageMgmtPort, ip_address]}
640 description: IP address of the server in the tenant network
641 value: {get_attr: [TenantPort, ip_address]}
642 management_ip_address:
643 description: IP address of the server in the management network
644 value: {get_attr: [ManagementPort, ip_address]}