Merge "Containerize Manila Share service"
[apex-tripleo-heat-templates.git] / puppet / controller-role.yaml
1 heat_template_version: pike
2
3 description: >
4   OpenStack controller node configured by Puppet.
5
6 parameters:
7   controllerExtraConfig:
8     default: {}
9     description: |
10       Deprecated. Use ControllerExtraConfig via parameter_defaults instead.
11     type: json
12   ControllerExtraConfig:
13     default: {}
14     description: |
15       Controller specific hiera configuration data to inject into the cluster.
16     type: json
17   ControllerIPs:
18     default: {}
19     description: >
20       A network mapped list of IPs to assign to Controllers in the following form:
21       {
22         "internal_api": ["a.b.c.d", "e.f.g.h"],
23         ...
24       }
25     type: json
26   Debug:
27     default: ''
28     description: Set to True to enable debugging on all services.
29     type: string
30   EnableLoadBalancer:
31     default: true
32     description: Whether to deploy a LoadBalancer on the Controller
33     type: boolean
34   ExtraConfig:
35     default: {}
36     description: |
37       Additional hieradata to inject into the cluster, note that
38       ControllerExtraConfig takes precedence over ExtraConfig.
39     type: json
40   OvercloudControlFlavor:
41     description: Flavor for control nodes to request when deploying.
42     default: baremetal
43     type: string
44     constraints:
45       - custom_constraint: nova.flavor
46   controllerImage:
47     type: string
48     default: overcloud-full
49     constraints:
50       - custom_constraint: glance.image
51   ImageUpdatePolicy:
52     default: 'REBUILD_PRESERVE_EPHEMERAL'
53     description: What policy to use when reconstructing instances. REBUILD for rebuilds, REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
54     type: string
55   KeyName:
56     default: default
57     description: Name of an existing Nova key pair to enable SSH access to the instances
58     type: string
59     constraints:
60       - custom_constraint: nova.keypair
61   NeutronPhysicalBridge:
62     default: 'br-ex'
63     description: An OVS bridge to create for accessing external networks.
64     type: string
65   NeutronPublicInterface:
66     default: nic1
67     description: Which interface to add to the NeutronPhysicalBridge.
68     type: string
69   ServiceNetMap:
70     default: {}
71     description: Mapping of service_name -> network name. Typically set
72                  via parameter_defaults in the resource registry.
73     type: json
74   EndpointMap:
75     default: {}
76     description: Mapping of service endpoint -> protocol. Typically set
77                  via parameter_defaults in the resource registry.
78     type: json
79   UpdateIdentifier:
80     default: ''
81     type: string
82     description: >
83       Setting to a previously unused value during stack-update will trigger
84       package update on all nodes
85   Hostname:
86     type: string
87     default: '' # Defaults to Heat created hostname
88   HostnameMap:
89     type: json
90     default: {}
91     description: Optional mapping to override hostnames
92   NetworkDeploymentActions:
93     type: comma_delimited_list
94     description: >
95       Heat action when to apply network configuration changes
96     default: ['CREATE']
97   NodeIndex:
98     type: number
99     default: 0
100   SoftwareConfigTransport:
101     default: POLL_SERVER_CFN
102     description: |
103       How the server should receive the metadata required for software configuration.
104     type: string
105     constraints:
106     - allowed_values: [POLL_SERVER_CFN, POLL_SERVER_HEAT, POLL_TEMP_URL, ZAQAR_MESSAGE]
107   CloudDomain:
108     default: 'localdomain'
109     type: string
110     description: >
111       The DNS domain used for the hosts. This must match the
112       overcloud_domain_name configured on the undercloud.
113   ControllerServerMetadata:
114     default: {}
115     description: >
116       Extra properties or metadata passed to Nova for the created nodes in
117       the overcloud. It's accessible via the Nova metadata API. This option is
118       role-specific and is merged with the values given to the ServerMetadata
119       parameter.
120     type: json
121   ServerMetadata:
122     default: {}
123     description: >
124       Extra properties or metadata passed to Nova for the created nodes in
125       the overcloud. It's accessible via the Nova metadata API. This applies to
126       all roles and is merged with a role-specific metadata parameter.
127     type: json
128   ControllerSchedulerHints:
129     type: json
130     description: Optional scheduler hints to pass to nova
131     default: {}
132   ServiceConfigSettings:
133     type: json
134     default: {}
135   ServiceNames:
136     type: comma_delimited_list
137     default: []
138   MonitoringSubscriptions:
139     type: comma_delimited_list
140     default: []
141   ServiceMetadataSettings:
142     type: json
143     default: {}
144   ConfigCommand:
145     type: string
146     description: Command which will be run whenever configuration data changes
147     default: os-refresh-config --timeout 14400
148   ConfigCollectSplay:
149     type: number
150     default: 30
151     description: |
152       Maximum amount of time to possibly to delay configuation collection
153       polling. Defaults to 30 seconds. Set to 0 to disable it which will cause
154       the configuration collection to occur as soon as the collection process
155       starts.  This setting is used to prevent the configuration collection
156       processes from polling all at the exact same time.
157   UpgradeInitCommand:
158     type: string
159     description: |
160       Command or script snippet to run on all overcloud nodes to
161       initialize the upgrade process. E.g. a repository switch.
162     default: ''
163   UpgradeInitCommonCommand:
164     type: string
165     description: |
166       Common commands required by the upgrades process. This should not
167       normally be modified by the operator and is set and unset in the
168       major-upgrade-composable-steps.yaml and major-upgrade-converge.yaml
169       environment files.
170     default: ''
171   DeploymentServerBlacklistDict:
172     default: {}
173     type: json
174     description: >
175       Map of server hostnames to blacklist from any triggered
176       deployments. If the value is 1, the server will be blacklisted. This
177       parameter is generated from the parent template.
178   RoleParameters:
179     type: json
180     description: Role Specific Parameters
181     default: {}
182   DeploymentSwiftDataMap:
183     type: json
184     description: |
185       Map of servers to Swift container and object for storing deployment data.
186       The keys are the Heat assigned hostnames, and the value is a map of the
187       container/object name in Swift. Example value:
188         overcloud-controller-0:
189           container: overcloud-controller
190           object: 0
191         overcloud-controller-1:
192           container: overcloud-controller
193           object: 1
194         overcloud-controller-2:
195           container: overcloud-controller
196           object: 2
197         overcloud-novacompute-0:
198           container: overcloud-compute
199           object: 0
200     default: {}
201
202 parameter_groups:
203 - label: deprecated
204   description: Do not use deprecated params, they will be removed.
205   parameters:
206   - controllerExtraConfig
207
208 conditions:
209   server_not_blacklisted:
210     not:
211       equals:
212         - {get_param: [DeploymentServerBlacklistDict, {get_param: Hostname}]}
213         - 1
214   deployment_swift_data_map_unset:
215     equals:
216       - get_param:
217           - DeploymentSwiftDataMap
218           - {get_param: Hostname}
219       - ""
220
221 resources:
222
223   Controller:
224     type: OS::TripleO::ControllerServer
225     metadata:
226       os-collect-config:
227         command: {get_param: ConfigCommand}
228         splay: {get_param: ConfigCollectSplay}
229     properties:
230       image: {get_param: controllerImage}
231       image_update_policy: {get_param: ImageUpdatePolicy}
232       flavor: {get_param: OvercloudControlFlavor}
233       key_name: {get_param: KeyName}
234       networks:
235         - network: ctlplane
236       user_data_format: SOFTWARE_CONFIG
237       user_data: {get_resource: UserData}
238       name:
239         str_replace:
240             template: {get_param: Hostname}
241             params: {get_param: HostnameMap}
242       software_config_transport: {get_param: SoftwareConfigTransport}
243       metadata:
244         map_merge:
245           - {get_param: ServerMetadata}
246           - {get_param: ControllerServerMetadata}
247           - {get_param: ServiceMetadataSettings}
248       scheduler_hints: {get_param: ControllerSchedulerHints}
249       deployment_swift_data:
250         if:
251           - deployment_swift_data_map_unset
252           - {}
253           - {get_param: [DeploymentSwiftDataMap,
254                          {get_param: Hostname}]}
255
256   # Combine the NodeAdminUserData and NodeUserData mime archives
257   UserData:
258     type: OS::Heat::MultipartMime
259     properties:
260       parts:
261       - config: {get_resource: NodeAdminUserData}
262         type: multipart
263       - config: {get_resource: NodeUserData}
264         type: multipart
265       - config: {get_resource: RoleUserData}
266         type: multipart
267
268   # Creates the "heat-admin" user if configured via the environment
269   # Should return a OS::Heat::MultipartMime reference via OS::stack_id
270   NodeAdminUserData:
271     type: OS::TripleO::NodeAdminUserData
272
273   # For optional operator additional userdata
274   # Should return a OS::Heat::MultipartMime reference via OS::stack_id
275   NodeUserData:
276     type: OS::TripleO::NodeUserData
277
278   # For optional operator role-specific userdata
279   # Should return a OS::Heat::MultipartMime reference via OS::stack_id
280   RoleUserData:
281     type: OS::TripleO::Controller::NodeUserData
282
283   ExternalPort:
284     type: OS::TripleO::Controller::Ports::ExternalPort
285     properties:
286       IPPool: {get_param: ControllerIPs}
287       NodeIndex: {get_param: NodeIndex}
288       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
289
290   InternalApiPort:
291     type: OS::TripleO::Controller::Ports::InternalApiPort
292     properties:
293       IPPool: {get_param: ControllerIPs}
294       NodeIndex: {get_param: NodeIndex}
295       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
296
297   StoragePort:
298     type: OS::TripleO::Controller::Ports::StoragePort
299     properties:
300       IPPool: {get_param: ControllerIPs}
301       NodeIndex: {get_param: NodeIndex}
302       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
303
304   StorageMgmtPort:
305     type: OS::TripleO::Controller::Ports::StorageMgmtPort
306     properties:
307       IPPool: {get_param: ControllerIPs}
308       NodeIndex: {get_param: NodeIndex}
309       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
310
311   TenantPort:
312     type: OS::TripleO::Controller::Ports::TenantPort
313     properties:
314       IPPool: {get_param: ControllerIPs}
315       NodeIndex: {get_param: NodeIndex}
316       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
317
318   ManagementPort:
319     type: OS::TripleO::Controller::Ports::ManagementPort
320     properties:
321       IPPool: {get_param: ControllerIPs}
322       NodeIndex: {get_param: NodeIndex}
323       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
324
325   NetIpMap:
326     type: OS::TripleO::Network::Ports::NetIpMap
327     properties:
328       ControlPlaneIp: {get_attr: [Controller, networks, ctlplane, 0]}
329       ExternalIp: {get_attr: [ExternalPort, ip_address]}
330       ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
331       ExternalIpUri: {get_attr: [ExternalPort, ip_address_uri]}
332       InternalApiIp: {get_attr: [InternalApiPort, ip_address]}
333       InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
334       InternalApiIpUri: {get_attr: [InternalApiPort, ip_address_uri]}
335       StorageIp: {get_attr: [StoragePort, ip_address]}
336       StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
337       StorageIpUri: {get_attr: [StoragePort, ip_address_uri]}
338       StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
339       StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
340       StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
341       TenantIp: {get_attr: [TenantPort, ip_address]}
342       TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
343       TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
344       ManagementIp: {get_attr: [ManagementPort, ip_address]}
345       ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
346       ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
347
348   NetHostMap:
349     type: OS::Heat::Value
350     properties:
351       type: json
352       value:
353         external:
354           fqdn:
355             list_join:
356             - '.'
357             - - {get_attr: [Controller, name]}
358               - external
359               - {get_param: CloudDomain}
360           short:
361             list_join:
362             - '.'
363             - - {get_attr: [Controller, name]}
364               - external
365         internal_api:
366           fqdn:
367             list_join:
368             - '.'
369             - - {get_attr: [Controller, name]}
370               - internalapi
371               - {get_param: CloudDomain}
372           short:
373             list_join:
374             - '.'
375             - - {get_attr: [Controller, name]}
376               - internalapi
377         storage:
378           fqdn:
379             list_join:
380             - '.'
381             - - {get_attr: [Controller, name]}
382               - storage
383               - {get_param: CloudDomain}
384           short:
385             list_join:
386             - '.'
387             - - {get_attr: [Controller, name]}
388               - storage
389         storage_mgmt:
390           fqdn:
391             list_join:
392             - '.'
393             - - {get_attr: [Controller, name]}
394               - storagemgmt
395               - {get_param: CloudDomain}
396           short:
397             list_join:
398             - '.'
399             - - {get_attr: [Controller, name]}
400               - storagemgmt
401         tenant:
402           fqdn:
403             list_join:
404             - '.'
405             - - {get_attr: [Controller, name]}
406               - tenant
407               - {get_param: CloudDomain}
408           short:
409             list_join:
410             - '.'
411             - - {get_attr: [Controller, name]}
412               - tenant
413         management:
414           fqdn:
415             list_join:
416             - '.'
417             - - {get_attr: [Controller, name]}
418               - management
419               - {get_param: CloudDomain}
420           short:
421             list_join:
422             - '.'
423             - - {get_attr: [Controller, name]}
424               - management
425         ctlplane:
426           fqdn:
427             list_join:
428             - '.'
429             - - {get_attr: [Controller, name]}
430               - ctlplane
431               - {get_param: CloudDomain}
432           short:
433             list_join:
434             - '.'
435             - - {get_attr: [Controller, name]}
436               - ctlplane
437
438   PreNetworkConfig:
439     type: OS::TripleO::Controller::PreNetworkConfig
440     properties:
441       server: {get_resource: Controller}
442       RoleParameters: {get_param: RoleParameters}
443       ServiceNames: {get_param: ServiceNames}
444       deployment_actions: {get_attr: [DeploymentActions, value]}
445
446   NetworkConfig:
447     type: OS::TripleO::Controller::Net::SoftwareConfig
448     properties:
449       ControlPlaneIp: {get_attr: [Controller, networks, ctlplane, 0]}
450       ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
451       InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
452       StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
453       StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
454       TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
455       ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
456
457   NetworkDeployment:
458     type: OS::TripleO::SoftwareDeployment
459     depends_on: PreNetworkConfig
460     properties:
461       name: NetworkDeployment
462       config: {get_resource: NetworkConfig}
463       server: {get_resource: Controller}
464       actions:
465         if:
466           - server_not_blacklisted
467           - {get_param: NetworkDeploymentActions}
468           - []
469       input_values:
470         bridge_name: {get_param: NeutronPhysicalBridge}
471         interface_name: {get_param: NeutronPublicInterface}
472
473   # Resource for site-specific injection of root certificate
474   NodeTLSCAData:
475     depends_on: NetworkDeployment
476     type: OS::TripleO::NodeTLSCAData
477     properties:
478       server: {get_resource: Controller}
479
480   # Resource for site-specific passing of private keys/certificates
481   NodeTLSData:
482     depends_on: NodeTLSCAData
483     type: OS::TripleO::NodeTLSData
484     properties:
485       server: {get_resource: Controller}
486       NodeIndex: {get_param: NodeIndex}
487
488   ControllerUpgradeInitConfig:
489     type: OS::Heat::SoftwareConfig
490     properties:
491       group: script
492       config:
493         list_join:
494         - ''
495         - - "#!/bin/bash\n\n"
496           - "if [[ -f /etc/resolv.conf.save ]] ; then rm /etc/resolv.conf.save; fi\n\n"
497           - get_param: UpgradeInitCommand
498           - get_param: UpgradeInitCommonCommand
499
500   # Note we may be able to make this conditional on UpgradeInitCommandNotEmpty
501   # but https://bugs.launchpad.net/heat/+bug/1649900 needs fixing first
502   ControllerUpgradeInitDeployment:
503     type: OS::Heat::SoftwareDeployment
504     depends_on: NetworkDeployment
505     properties:
506       name: ControllerUpgradeInitDeployment
507       actions:
508         if:
509           - server_not_blacklisted
510           - ['CREATE', 'UPDATE']
511           - []
512       server: {get_resource: Controller}
513       config: {get_resource: ControllerUpgradeInitConfig}
514
515   ControllerDeployment:
516     type: OS::TripleO::SoftwareDeployment
517     depends_on: ControllerUpgradeInitDeployment
518     properties:
519       name: ControllerDeployment
520       actions:
521         if:
522           - server_not_blacklisted
523           - ['CREATE', 'UPDATE']
524           - []
525       config: {get_resource: ControllerConfig}
526       server: {get_resource: Controller}
527       input_values:
528         enable_load_balancer: {get_param: EnableLoadBalancer}
529         enable_package_upgrade: {get_attr: [UpdateDeployment, update_managed_packages]}
530
531   # Map heat metadata into hiera datafiles
532   ControllerConfig:
533     type: OS::Heat::StructuredConfig
534     properties:
535       group: hiera
536       config:
537         hierarchy:
538           - '"%{::uuid}"'
539           - heat_config_%{::deploy_config_name}
540           - config_step
541           - controller_extraconfig
542           - extraconfig
543           - service_configs
544           - service_names
545           - controller
546           - bootstrap_node # provided by BootstrapNodeConfig
547           - all_nodes # provided by allNodesConfig
548           - vip_data # provided by allNodesConfig
549           - '"%{::osfamily}"'
550           - neutron_bigswitch_data # Optionally provided by ControllerExtraConfigPre
551           - neutron_cisco_data # Optionally provided by ControllerExtraConfigPre
552           - cisco_n1kv_data # Optionally provided by ControllerExtraConfigPre
553           - midonet_data #Optionally provided by AllNodesExtraConfig
554           - cisco_aci_data # Optionally provided by ControllerExtraConfigPre
555         merge_behavior: deeper
556         datafiles:
557           service_names:
558             service_names: {get_param: ServiceNames}
559             sensu::subscriptions: {get_param: MonitoringSubscriptions}
560           service_configs:
561             map_replace:
562               - {get_param: ServiceConfigSettings}
563               - values: {get_attr: [NetIpMap, net_ip_map]}
564           controller_extraconfig:
565             map_merge:
566               - {get_param: controllerExtraConfig}
567               - {get_param: ControllerExtraConfig}
568           extraconfig: {get_param: ExtraConfig}
569           controller:
570             enable_load_balancer: {get_input: enable_load_balancer}
571
572             # Misc
573             tripleo::haproxy::service_certificate: {get_attr: [NodeTLSData, deployed_ssl_certificate_path]}
574             tripleo::packages::enable_upgrade: {get_input: enable_package_upgrade}
575             fqdn_internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
576             fqdn_storage: {get_attr: [NetHostMap, value, storage, fqdn]}
577             fqdn_storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
578             fqdn_tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
579             fqdn_management: {get_attr: [NetHostMap, value, management, fqdn]}
580             fqdn_ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
581             fqdn_external: {get_attr: [NetHostMap, value, external, fqdn]}
582
583   # Hook for site-specific additional pre-deployment config, e.g extra hieradata
584   ControllerExtraConfigPre:
585     depends_on: ControllerDeployment
586     type: OS::TripleO::ControllerExtraConfigPre
587     # We have to use conditions here so that we don't break backwards
588     # compatibility with templates everywhere
589     condition: server_not_blacklisted
590     properties:
591         server: {get_resource: Controller}
592
593   # Hook for site-specific additional pre-deployment config,
594   # applying to all nodes, e.g node registration/unregistration
595   NodeExtraConfig:
596     depends_on: [ControllerExtraConfigPre, NodeTLSData]
597     type: OS::TripleO::NodeExtraConfig
598     # We have to use conditions here so that we don't break backwards
599     # compatibility with templates everywhere
600     condition: server_not_blacklisted
601     properties:
602         server: {get_resource: Controller}
603
604   UpdateConfig:
605     type: OS::TripleO::Tasks::PackageUpdate
606
607   UpdateDeployment:
608     type: OS::Heat::SoftwareDeployment
609     depends_on: NetworkDeployment
610     properties:
611       name: UpdateDeployment
612       actions:
613         if:
614           - server_not_blacklisted
615           - ['CREATE', 'UPDATE']
616           - []
617       config: {get_resource: UpdateConfig}
618       server: {get_resource: Controller}
619       input_values:
620         update_identifier:
621           get_param: UpdateIdentifier
622
623   DeploymentActions:
624     type: OS::Heat::Value
625     properties:
626       value:
627         if:
628           - server_not_blacklisted
629           - ['CREATE', 'UPDATE']
630           - []
631
632   SshHostPubKey:
633     type: OS::TripleO::Ssh::HostPubKey
634     depends_on: ControllerDeployment
635     properties:
636         server: {get_resource: Controller}
637         deployment_actions: {get_attr: [DeploymentActions, value]}
638
639 outputs:
640   ip_address:
641     description: IP address of the server in the ctlplane network
642     value: {get_attr: [Controller, networks, ctlplane, 0]}
643   external_ip_address:
644     description: IP address of the server in the external network
645     value: {get_attr: [ExternalPort, ip_address]}
646   internal_api_ip_address:
647     description: IP address of the server in the internal_api network
648     value: {get_attr: [InternalApiPort, ip_address]}
649   storage_ip_address:
650     description: IP address of the server in the storage network
651     value: {get_attr: [StoragePort, ip_address]}
652   storage_mgmt_ip_address:
653     description: IP address of the server in the storage_mgmt network
654     value: {get_attr: [StorageMgmtPort, ip_address]}
655   tenant_ip_address:
656     description: IP address of the server in the tenant network
657     value: {get_attr: [TenantPort, ip_address]}
658   management_ip_address:
659     description: IP address of the server in the management network
660     value: {get_attr: [ManagementPort, ip_address]}
661   deployed_server_port_map:
662     description:
663       Map of Heat created hostname of the server to ip address. This is the
664       hostname before it has been mapped with the HostnameMap parameter, and
665       the IP address from the ctlplane network. This map can be used to construct
666       the DeployedServerPortMap parameter when using split-stack.
667     value:
668       map_replace:
669         - hostname:
670             fixed_ips:
671               - ip_address: {get_attr: [Controller, networks, ctlplane, 0]}
672         - keys:
673             hostname:
674               list_join:
675                 - '-'
676                 - - {get_param: Hostname}
677                   - ctlplane
678   deployed_server_deployment_swift_data_map:
679     description:
680       Map of Heat created hostname of the server to the Swift container and object
681       used to created the temporary url for metadata polling with
682       os-collect-config.
683     value:
684       map_replace:
685         - hostname:
686             container:
687               str_split:
688                 - '/'
689                 - {get_attr: [Controller, os_collect_config, request, metadata_url]}
690                 - 5
691             object:
692               str_split:
693                 - '?'
694                 - str_split:
695                     - '/'
696                     - {get_attr: [Controller, os_collect_config, request, metadata_url]}
697                     - 6
698                 - 0
699         - keys: {hostname: {get_param: Hostname}}
700   hostname:
701     description: Hostname of the server
702     value: {get_attr: [Controller, name]}
703   hostname_map:
704     description: Mapping of network names to hostnames
705     value:
706       external: {get_attr: [NetHostMap, value, external, fqdn]}
707       internal_api: {get_attr: [NetHostMap, value, internal_api, fqdn]}
708       storage: {get_attr: [NetHostMap, value, storage, fqdn]}
709       storage_mgmt: {get_attr: [NetHostMap, value, storage_mgmt, fqdn]}
710       tenant: {get_attr: [NetHostMap, value, tenant, fqdn]}
711       management: {get_attr: [NetHostMap, value, management, fqdn]}
712       ctlplane: {get_attr: [NetHostMap, value, ctlplane, fqdn]}
713   hosts_entry:
714     description: >
715       Server's IP address and hostname in the /etc/hosts format
716     value:
717       str_replace:
718         template: |
719           PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST
720           EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST
721           INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST
722           STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST
723           STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST
724           TENANTIP TENANTHOST.DOMAIN TENANTHOST
725           MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST
726           CTLPLANEIP CTLPLANEHOST.DOMAIN CTLPLANEHOST
727         params:
728           PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ControllerHostnameResolveNetwork]}]}
729           DOMAIN: {get_param: CloudDomain}
730           PRIMARYHOST: {get_attr: [Controller, name]}
731           EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
732           EXTERNALHOST: {get_attr: [NetHostMap, value, external, short]}
733           INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
734           INTERNAL_APIHOST: {get_attr: [NetHostMap, value, internal_api, short]}
735           STORAGEIP: {get_attr: [StoragePort, ip_address]}
736           STORAGEHOST: {get_attr: [NetHostMap, value, storage, short]}
737           STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
738           STORAGE_MGMTHOST: {get_attr: [NetHostMap, value, storage_mgmt, short]}
739           TENANTIP: {get_attr: [TenantPort, ip_address]}
740           TENANTHOST: {get_attr: [NetHostMap, value, tenant, short]}
741           MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
742           MANAGEMENTHOST: {get_attr: [NetHostMap, value, management, short]}
743           CTLPLANEIP: {get_attr: [Controller, networks, ctlplane, 0]}
744           CTLPLANEHOST: {get_attr: [NetHostMap, value, ctlplane, short]}
745   known_hosts_entry:
746     description: Entry for ssh known hosts
747     value:
748       str_replace:
749         template: "PRIMARYIP,PRIMARYHOST.DOMAIN,PRIMARYHOST,\
750 EXTERNALIP,EXTERNALHOST.DOMAIN,EXTERNALHOST,\
751 INTERNAL_APIIP,INTERNAL_APIHOST.DOMAIN,INTERNAL_APIHOST,\
752 STORAGEIP,STORAGEHOST.DOMAIN,STORAGEHOST,\
753 STORAGE_MGMTIP,STORAGE_MGMTHOST.DOMAIN,STORAGE_MGMTHOST,\
754 TENANTIP,TENANTHOST.DOMAIN,TENANTHOST,\
755 MANAGEMENTIP,MANAGEMENTHOST.DOMAIN,MANAGEMENTHOST,\
756 CTLPLANEIP,CTLPLANEHOST.DOMAIN,CTLPLANEHOST HOSTSSHPUBKEY"
757         params:
758           PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ControllerHostnameResolveNetwork]}]}
759           DOMAIN: {get_param: CloudDomain}
760           PRIMARYHOST: {get_attr: [Controller, name]}
761           EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
762           EXTERNALHOST: {get_attr: [NetHostMap, value, external, short]}
763           INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
764           INTERNAL_APIHOST: {get_attr: [NetHostMap, value, internal_api, short]}
765           STORAGEIP: {get_attr: [StoragePort, ip_address]}
766           STORAGEHOST: {get_attr: [NetHostMap, value, storage, short]}
767           STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
768           STORAGE_MGMTHOST: {get_attr: [NetHostMap, value, storage_mgmt, short]}
769           TENANTIP: {get_attr: [TenantPort, ip_address]}
770           TENANTHOST: {get_attr: [NetHostMap, value, tenant, short]}
771           MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
772           MANAGEMENTHOST: {get_attr: [NetHostMap, value, management, short]}
773           CTLPLANEIP: {get_attr: [Controller, networks, ctlplane, 0]}
774           CTLPLANEHOST: {get_attr: [NetHostMap, value, ctlplane, short]}
775           HOSTSSHPUBKEY: {get_attr: [SshHostPubKey, ecdsa]}
776   nova_server_resource:
777     description: Heat resource handle for the Nova compute server
778     value:
779       {get_resource: Controller}
780     condition: server_not_blacklisted
781   tls_key_modulus_md5:
782     description: MD5 checksum of the TLS Key Modulus
783     value: {get_attr: [NodeTLSData, key_modulus_md5]}
784   tls_cert_modulus_md5:
785     description: MD5 checksum of the TLS Certificate Modulus
786     value: {get_attr: [NodeTLSData, cert_modulus_md5]}
787   os_collect_config:
788     description: The os-collect-config configuration associated with this server resource
789     value: {get_attr: [Controller, os_collect_config]}