Merge "Remove deprecated net_ip_subnet_map output"
[apex-tripleo-heat-templates.git] / puppet / controller.yaml
1 heat_template_version: 2016-10-14
2
3 description: >
4   OpenStack controller node configured by Puppet.
5
6 parameters:
7   AdminPassword:
8     description: The password for the keystone admin account, used for monitoring, querying neutron etc.
9     type: string
10     hidden: true
11   AodhPassword:
12     description: The password for the aodh services.
13     type: string
14     hidden: true
15   controllerExtraConfig:
16     default: {}
17     description: |
18       Deprecated. Use ControllerExtraConfig via parameter_defaults instead.
19     type: json
20   ControllerExtraConfig:
21     default: {}
22     description: |
23       Controller specific hiera configuration data to inject into the cluster.
24     type: json
25   ControllerIPs:
26     default: {}
27     description: >
28       A network mapped list of IPs to assign to Controllers in the following form:
29       {
30         "internal_api": ["a.b.c.d", "e.f.g.h"],
31         ...
32       }
33     type: json
34   ControlVirtualInterface:
35     default: 'br-ex'
36     description: Interface where virtual ip will be assigned.
37     type: string
38   CorosyncIPv6:
39     default: false
40     description: Enable IPv6 in Corosync
41     type: boolean
42   Debug:
43     default: ''
44     description: Set to True to enable debugging on all services.
45     type: string
46   EnableFencing:
47     default: false
48     description: Whether to enable fencing in Pacemaker or not.
49     type: boolean
50   EnableGalera:
51     default: true
52     description: Whether to use Galera instead of regular MariaDB.
53     type: boolean
54   EnableLoadBalancer:
55     default: true
56     description: Whether to deploy a LoadBalancer on the Controller
57     type: boolean
58   ExtraConfig:
59     default: {}
60     description: |
61       Additional hieradata to inject into the cluster, note that
62       ControllerExtraConfig takes precedence over ExtraConfig.
63     type: json
64   FencingConfig:
65     default: {}
66     description: |
67       Pacemaker fencing configuration. The JSON should have
68       the following structure:
69         {
70           "devices": [
71             {
72               "agent": "AGENT_NAME",
73               "host_mac": "HOST_MAC_ADDRESS",
74               "params": {"PARAM_NAME": "PARAM_VALUE"}
75             }
76           ]
77         }
78       For instance:
79         {
80           "devices": [
81             {
82               "agent": "fence_xvm",
83               "host_mac": "52:54:00:aa:bb:cc",
84               "params": {
85                 "multicast_address": "225.0.0.12",
86                 "port": "baremetal_0",
87                 "manage_fw": true,
88                 "manage_key_file": true,
89                 "key_file": "/etc/fence_xvm.key",
90                 "key_file_password": "abcdef"
91               }
92             }
93           ]
94         }
95     type: json
96   OvercloudControlFlavor:
97     description: Flavor for control nodes to request when deploying.
98     default: baremetal
99     type: string
100     constraints:
101       - custom_constraint: nova.flavor
102   HAProxyStatsPassword:
103     description: Password for HAProxy stats endpoint
104     type: string
105   HAProxyStatsUser:
106     description: User for HAProxy stats endpoint
107     default: admin
108     type: string
109   HAProxySyslogAddress:
110     default: /dev/log
111     description: Syslog address where HAproxy will send its log
112     type: string
113   HeatAuthEncryptionKey:
114     description: Auth encryption key for heat-engine
115     type: string
116     hidden: true
117   HorizonSecret:
118     description: Secret key for Django
119     type: string
120     hidden: true
121   controllerImage:
122     type: string
123     default: overcloud-full
124     constraints:
125       - custom_constraint: glance.image
126   ImageUpdatePolicy:
127     default: 'REBUILD_PRESERVE_EPHEMERAL'
128     description: What policy to use when reconstructing instances. REBUILD for rebuilds, REBUILD_PRESERVE_EPHEMERAL to preserve /mnt.
129     type: string
130   InstanceNameTemplate:
131     default: 'instance-%08x'
132     description: Template string to be used to generate instance names
133     type: string
134   KeyName:
135     default: default
136     description: Name of an existing Nova key pair to enable SSH access to the instances
137     type: string
138     constraints:
139       - custom_constraint: nova.keypair
140   ManageFirewall:
141     default: false
142     description: Whether to manage IPtables rules.
143     type: boolean
144   MemcachedIPv6:
145     default: false
146     description: Enable IPv6 features in Memcached.
147     type: boolean
148   PurgeFirewallRules:
149     default: false
150     description: Whether IPtables rules should be purged before setting up the new ones.
151     type: boolean
152   MysqlClusterUniquePart:
153     description: A unique identifier of the MySQL cluster the controller is in.
154     type: string
155     default: 'unset'  # Has to be here because of the ignored empty value bug
156     # Drop the validation: https://bugs.launchpad.net/tripleo/+bug/1405446
157     # constraints:
158     # - length: {min: 4, max: 10}
159   MysqlInnodbBufferPoolSize:
160     description: >
161         Specifies the size of the buffer pool in megabytes. Setting to
162         zero should be interpreted as "no value" and will defer to the
163         lower level default.
164     type: number
165     default: 0
166   MysqlMaxConnections:
167     description: Configures MySQL max_connections config setting
168     type: number
169     default: 4096
170   MysqlClustercheckPassword:
171     type: string
172     hidden: true
173   MysqlRootPassword:
174     type: string
175     hidden: true
176     default: ''  # Has to be here because of the ignored empty value bug
177   NeutronMetadataProxySharedSecret:
178     description: Shared secret to prevent spoofing
179     type: string
180     hidden: true
181   NeutronPassword:
182     description: The password for the neutron service and db account, used by neutron agents.
183     type: string
184     hidden: true
185   NeutronPublicInterface:
186     default: nic1
187     description: What interface to bridge onto br-ex for network nodes.
188     type: string
189   NovaEnableDBPurge:
190     default: true
191     description: |
192         Whether to create cron job for purging soft deleted rows in Nova database.
193     type: boolean
194   NovaIPv6:
195     default: false
196     description: Enable IPv6 features in Nova
197     type: boolean
198   NovaPassword:
199     description: The password for the nova service and db account, used by nova-api.
200     type: string
201     hidden: true
202   PcsdPassword:
203     type: string
204     description: The password for the 'pcsd' user.
205     hidden: true
206   PublicVirtualInterface:
207     default: 'br-ex'
208     description: >
209         Specifies the interface where the public-facing virtual ip will be assigned.
210         This should be int_public when a VLAN is being used.
211     type: string
212   RabbitCookie:
213     type: string
214     default: ''  # Has to be here because of the ignored empty value bug
215     hidden: true
216   RabbitPassword:
217     description: The password for RabbitMQ
218     type: string
219     hidden: true
220   RabbitUserName:
221     default: guest
222     description: The username for RabbitMQ
223     type: string
224   RabbitClientUseSSL:
225     default: false
226     description: >
227         Rabbit client subscriber parameter to specify
228         an SSL connection to the RabbitMQ host.
229     type: string
230   RabbitClientPort:
231     default: 5672
232     description: Set rabbit subscriber port, change this if using SSL
233     type: number
234   RedisPassword:
235     description: The password for Redis
236     type: string
237     hidden: true
238   RedisVirtualIP:
239     type: string
240     default: ''  # Has to be here because of the ignored empty value bug
241   RedisVirtualIPUri:
242     type: string
243     default: ''  # Has to be here because of the ignored empty value bug
244     description: An IP address which is wrapped in brackets in case of IPv6
245   SwiftHashSuffix:
246     description: A random string to be used as a salt when hashing to determine mappings
247       in the ring.
248     hidden: true
249     type: string
250   UpgradeLevelNovaCompute:
251     type: string
252     description: Nova Compute upgrade level
253     default: ''
254   MysqlVirtualIP:
255     type: string
256     default: ''
257   EnablePackageInstall:
258     default: 'false'
259     description: Set to true to enable package installation via Puppet
260     type: boolean
261   ServiceNetMap:
262     default: {}
263     description: Mapping of service_name -> network name. Typically set
264                  via parameter_defaults in the resource registry.
265     type: json
266   EndpointMap:
267     default: {}
268     description: Mapping of service endpoint -> protocol. Typically set
269                  via parameter_defaults in the resource registry.
270     type: json
271   UpdateIdentifier:
272     default: ''
273     type: string
274     description: >
275       Setting to a previously unused value during stack-update will trigger
276       package update on all nodes
277   Hostname:
278     type: string
279     default: '' # Defaults to Heat created hostname
280   HostnameMap:
281     type: json
282     default: {}
283     description: Optional mapping to override hostnames
284   NetworkDeploymentActions:
285     type: comma_delimited_list
286     description: >
287       Heat action when to apply network configuration changes
288     default: ['CREATE']
289   NodeIndex:
290     type: number
291     default: 0
292   SoftwareConfigTransport:
293     default: POLL_SERVER_CFN
294     description: |
295       How the server should receive the metadata required for software configuration.
296     type: string
297     constraints:
298     - allowed_values: [POLL_SERVER_CFN, POLL_SERVER_HEAT, POLL_TEMP_URL, ZAQAR_MESSAGE]
299   CloudDomain:
300     type: string
301     description: >
302       The DNS domain used for the hosts. This should match the dhcp_domain
303       configured in the Undercloud neutron. Defaults to localdomain.
304   ServerMetadata:
305     default: {}
306     description: >
307       Extra properties or metadata passed to Nova for the created nodes in
308       the overcloud. It's accessible via the Nova metadata API.
309     type: json
310   ControllerSchedulerHints:
311     type: json
312     description: Optional scheduler hints to pass to nova
313     default: {}
314   ServiceConfigSettings:
315     type: json
316     default: {}
317   ServiceNames:
318     type: comma_delimited_list
319     default: []
320   ConfigCommand:
321     type: string
322     description: Command which will be run whenever configuration data changes
323     default: os-refresh-config --timeout 14400
324
325 parameter_groups:
326 - label: deprecated
327   description: Do not use deprecated params, they will be removed.
328   parameters:
329   - controllerExtraConfig
330
331 resources:
332
333   Controller:
334     type: OS::TripleO::Server
335     metadata:
336       os-collect-config:
337         command: {get_param: ConfigCommand}
338     properties:
339       image: {get_param: controllerImage}
340       image_update_policy: {get_param: ImageUpdatePolicy}
341       flavor: {get_param: OvercloudControlFlavor}
342       key_name: {get_param: KeyName}
343       networks:
344         - network: ctlplane
345       user_data_format: SOFTWARE_CONFIG
346       user_data: {get_resource: UserData}
347       name:
348         str_replace:
349             template: {get_param: Hostname}
350             params: {get_param: HostnameMap}
351       software_config_transport: {get_param: SoftwareConfigTransport}
352       metadata: {get_param: ServerMetadata}
353       scheduler_hints: {get_param: ControllerSchedulerHints}
354
355   # Combine the NodeAdminUserData and NodeUserData mime archives
356   UserData:
357     type: OS::Heat::MultipartMime
358     properties:
359       parts:
360       - config: {get_resource: NodeAdminUserData}
361         type: multipart
362       - config: {get_resource: NodeUserData}
363         type: multipart
364
365   # Creates the "heat-admin" user if configured via the environment
366   # Should return a OS::Heat::MultipartMime reference via OS::stack_id
367   NodeAdminUserData:
368     type: OS::TripleO::NodeAdminUserData
369
370   # For optional operator additional userdata
371   # Should return a OS::Heat::MultipartMime reference via OS::stack_id
372   NodeUserData:
373     type: OS::TripleO::NodeUserData
374
375   ExternalPort:
376     type: OS::TripleO::Controller::Ports::ExternalPort
377     properties:
378       IPPool: {get_param: ControllerIPs}
379       NodeIndex: {get_param: NodeIndex}
380       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
381
382   InternalApiPort:
383     type: OS::TripleO::Controller::Ports::InternalApiPort
384     properties:
385       IPPool: {get_param: ControllerIPs}
386       NodeIndex: {get_param: NodeIndex}
387       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
388
389   StoragePort:
390     type: OS::TripleO::Controller::Ports::StoragePort
391     properties:
392       IPPool: {get_param: ControllerIPs}
393       NodeIndex: {get_param: NodeIndex}
394       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
395
396   StorageMgmtPort:
397     type: OS::TripleO::Controller::Ports::StorageMgmtPort
398     properties:
399       IPPool: {get_param: ControllerIPs}
400       NodeIndex: {get_param: NodeIndex}
401       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
402
403   TenantPort:
404     type: OS::TripleO::Controller::Ports::TenantPort
405     properties:
406       IPPool: {get_param: ControllerIPs}
407       NodeIndex: {get_param: NodeIndex}
408       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
409
410   ManagementPort:
411     type: OS::TripleO::Controller::Ports::ManagementPort
412     properties:
413       IPPool: {get_param: ControllerIPs}
414       NodeIndex: {get_param: NodeIndex}
415       ControlPlaneIP: {get_attr: [Controller, networks, ctlplane, 0]}
416
417   NetIpMap:
418     type: OS::TripleO::Network::Ports::NetIpMap
419     properties:
420       ControlPlaneIp: {get_attr: [Controller, networks, ctlplane, 0]}
421       ExternalIp: {get_attr: [ExternalPort, ip_address]}
422       ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
423       ExternalIpUri: {get_attr: [ExternalPort, ip_address_uri]}
424       InternalApiIp: {get_attr: [InternalApiPort, ip_address]}
425       InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
426       InternalApiIpUri: {get_attr: [InternalApiPort, ip_address_uri]}
427       StorageIp: {get_attr: [StoragePort, ip_address]}
428       StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
429       StorageIpUri: {get_attr: [StoragePort, ip_address_uri]}
430       StorageMgmtIp: {get_attr: [StorageMgmtPort, ip_address]}
431       StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
432       StorageMgmtIpUri: {get_attr: [StorageMgmtPort, ip_address_uri]}
433       TenantIp: {get_attr: [TenantPort, ip_address]}
434       TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
435       TenantIpUri: {get_attr: [TenantPort, ip_address_uri]}
436       ManagementIp: {get_attr: [ManagementPort, ip_address]}
437       ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
438       ManagementIpUri: {get_attr: [ManagementPort, ip_address_uri]}
439
440   NetworkConfig:
441     type: OS::TripleO::Controller::Net::SoftwareConfig
442     properties:
443       ControlPlaneIp: {get_attr: [Controller, networks, ctlplane, 0]}
444       ExternalIpSubnet: {get_attr: [ExternalPort, ip_subnet]}
445       InternalApiIpSubnet: {get_attr: [InternalApiPort, ip_subnet]}
446       StorageIpSubnet: {get_attr: [StoragePort, ip_subnet]}
447       StorageMgmtIpSubnet: {get_attr: [StorageMgmtPort, ip_subnet]}
448       TenantIpSubnet: {get_attr: [TenantPort, ip_subnet]}
449       ManagementIpSubnet: {get_attr: [ManagementPort, ip_subnet]}
450
451   NetworkDeployment:
452     type: OS::TripleO::SoftwareDeployment
453     properties:
454       name: NetworkDeployment
455       config: {get_resource: NetworkConfig}
456       server: {get_resource: Controller}
457       actions: {get_param: NetworkDeploymentActions}
458       input_values:
459         bridge_name: br-ex
460         interface_name: {get_param: NeutronPublicInterface}
461
462   # Resource for site-specific injection of root certificate
463   NodeTLSCAData:
464     depends_on: NetworkDeployment
465     type: OS::TripleO::NodeTLSCAData
466     properties:
467       server: {get_resource: Controller}
468
469   # Resource for site-specific passing of private keys/certificates
470   NodeTLSData:
471     depends_on: NodeTLSCAData
472     type: OS::TripleO::NodeTLSData
473     properties:
474       server: {get_resource: Controller}
475       NodeIndex: {get_param: NodeIndex}
476
477
478   ControllerDeployment:
479     type: OS::TripleO::SoftwareDeployment
480     depends_on: NetworkDeployment
481     properties:
482       name: ControllerDeployment
483       config: {get_resource: ControllerConfig}
484       server: {get_resource: Controller}
485       input_values:
486         bootstack_nodeid: {get_attr: [Controller, name]}
487         haproxy_log_address: {get_param: HAProxySyslogAddress}
488         haproxy_stats_password: {get_param: HAProxyStatsPassword}
489         haproxy_stats_user: {get_param: HAProxyStatsUser}
490         heat_auth_encryption_key: {get_param: HeatAuthEncryptionKey}
491         horizon_secret: {get_param: HorizonSecret}
492         admin_password: {get_param: AdminPassword}
493         debug: {get_param: Debug}
494         keystone_identity_uri: { get_param: [EndpointMap, KeystoneAdmin, uri_no_suffix] }
495         keystone_auth_uri: {get_param: [EndpointMap, KeystoneInternal, uri] }
496         keystone_ec2_uri: { get_param: [EndpointMap, KeystoneEC2, uri] }
497         enable_fencing: {get_param: EnableFencing}
498         enable_galera: {get_param: EnableGalera}
499         enable_load_balancer: {get_param: EnableLoadBalancer}
500         manage_firewall: {get_param: ManageFirewall}
501         purge_firewall_rules: {get_param: PurgeFirewallRules}
502         mysql_innodb_buffer_pool_size: {get_param: MysqlInnodbBufferPoolSize}
503         mysql_max_connections: {get_param: MysqlMaxConnections}
504         mysql_root_password: {get_param: MysqlRootPassword}
505         mysql_clustercheck_password: {get_param: MysqlClustercheckPassword}
506         mysql_cluster_name:
507           str_replace:
508             template: tripleo-CLUSTER
509             params:
510               CLUSTER: {get_param: MysqlClusterUniquePart}
511         neutron_metadata_proxy_shared_secret: {get_param: NeutronMetadataProxySharedSecret}
512         aodh_internal_url: { get_param: [ EndpointMap, AodhInternal, uri ] }
513         aodh_public_url: { get_param: [ EndpointMap, AodhPublic, uri ] }
514         aodh_admin_url: { get_param: [ EndpointMap, AodhAdmin, uri ] }
515         ceilometer_coordination_url:
516           list_join:
517             - ''
518             - - 'redis://:'
519               - {get_param: RedisPassword}
520               - '@'
521               - {get_param: RedisVirtualIPUri}
522               - ':6379/'
523         nova_enable_db_purge: {get_param: NovaEnableDBPurge}
524         nova_ipv6: {get_param: NovaIPv6}
525         corosync_ipv6: {get_param: CorosyncIPv6}
526         memcached_ipv6: {get_param: MemcachedIPv6}
527         nova_password: {get_param: NovaPassword}
528         upgrade_level_nova_compute: {get_param: UpgradeLevelNovaCompute}
529         instance_name_template: {get_param: InstanceNameTemplate}
530         fencing_config: {get_param: FencingConfig}
531         pcsd_password: {get_param: PcsdPassword}
532         rabbit_username: {get_param: RabbitUserName}
533         rabbit_password: {get_param: RabbitPassword}
534         rabbit_cookie: {get_param: RabbitCookie}
535         rabbit_client_use_ssl: {get_param: RabbitClientUseSSL}
536         rabbit_client_port: {get_param: RabbitClientPort}
537         control_virtual_interface: {get_param: ControlVirtualInterface}
538         public_virtual_interface: {get_param: PublicVirtualInterface}
539         swift_hash_suffix: {get_param: SwiftHashSuffix}
540         enable_package_install: {get_param: EnablePackageInstall}
541         enable_package_upgrade: {get_attr: [UpdateDeployment, update_managed_packages]}
542         swift_proxy_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, SwiftProxyNetwork]}]}
543         swift_management_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, SwiftMgmtNetwork]}]}
544         cinder_iscsi_network:
545           str_replace:
546             template: "'IP'"
547             params:
548               IP: {get_attr: [NetIpMap, net_ip_uri_map, {get_param: [ServiceNetMap, CinderIscsiNetwork]}]}
549         cinder_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CinderApiNetwork]}]}
550         glance_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GlanceApiNetwork]}]}
551         glance_registry_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GlanceRegistryNetwork]}]}
552         glance_api_servers: { get_param: [EndpointMap, GlanceInternal, uri]}
553         heat_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, HeatApiNetwork]}]}
554         keystone_public_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, KeystonePublicApiNetwork]}]}
555         keystone_admin_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, KeystoneAdminApiNetwork]}]}
556         manila_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ManilaApiNetwork]}]}
557         mongo_db_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, MongodbNetwork]}]}
558         neutron_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NeutronApiNetwork]}]}
559         neutron_local_ip: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NeutronTenantNetwork]}]}
560         ceilometer_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CeilometerApiNetwork]}]}
561         aodh_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, AodhApiNetwork]}]}
562         gnocchi_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, GnocchiApiNetwork]}]}
563         nova_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NovaApiNetwork]}]}
564         nova_metadata_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, NovaMetadataNetwork]}]}
565         horizon_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, HorizonNetwork]}]}
566         horizon_subnet:
567           str_replace:
568             template: "['SUBNET']"
569             params:
570               SUBNET:
571                 get_attr:
572                   - NetIpMap
573                   - net_ip_map
574                   - str_replace:
575                       template: "NETWORK_subnet"
576                       params:
577                         NETWORK: {get_param: [ServiceNetMap, HorizonNetwork]}
578         rabbitmq_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RabbitmqNetwork]}]}
579         redis_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, RedisNetwork]}]}
580         redis_vip: {get_param: RedisVirtualIP}
581         sahara_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, SaharaApiNetwork]}]}
582         memcached_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, MemcachedNetwork]}]}
583         mysql_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, MysqlNetwork]}]}
584         mysql_virtual_ip: {get_param: MysqlVirtualIP}
585         ceph_cluster_network:
586           get_attr:
587             - NetIpMap
588             - net_ip_map
589             - str_replace:
590                 template: "NETWORK_subnet"
591                 params:
592                   NETWORK: {get_param: [ServiceNetMap, CephClusterNetwork]}
593         ceph_public_network:
594           get_attr:
595             - NetIpMap
596             - net_ip_map
597             - str_replace:
598                 template: "NETWORK_subnet"
599                 params:
600                   NETWORK: {get_param: [ServiceNetMap, CephPublicNetwork]}
601         ceph_public_ip: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, CephPublicNetwork]}]}
602         ironic_api_network: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, IronicApiNetwork]}]}
603
604   # Map heat metadata into hiera datafiles
605   ControllerConfig:
606     type: OS::Heat::StructuredConfig
607     properties:
608       group: os-apply-config
609       config:
610         hiera:
611           hierarchy:
612             - '"%{::uuid}"'
613             - heat_config_%{::deploy_config_name}
614             - controller_extraconfig
615             - extraconfig
616             - service_configs
617             - service_names
618             - controller
619             - swift_devices_and_proxy # provided by SwiftDevicesAndProxyConfig
620             - ceph_cluster # provided by CephClusterConfig
621             - ceph
622             - bootstrap_node # provided by BootstrapNodeConfig
623             - all_nodes # provided by allNodesConfig
624             - vip_data # provided by vip-config
625             - '"%{::osfamily}"'
626             - network
627             - cinder_dellsc_data # Optionally provided by ControllerExtraConfigPre
628             - cinder_netapp_data # Optionally provided by ControllerExtraConfigPre
629             - cinder_eqlx_data # Optionally provided by ControllerExtraConfigPre
630             - neutron_bigswitch_data # Optionally provided by ControllerExtraConfigPre
631             - neutron_cisco_data # Optionally provided by ControllerExtraConfigPre
632             - cisco_n1kv_data # Optionally provided by ControllerExtraConfigPre
633             - midonet_data #Optionally provided by AllNodesExtraConfig
634           merge_behavior: deeper
635           datafiles:
636             service_names:
637               mapped_data:
638                 service_names: {get_param: ServiceNames}
639             service_configs:
640               mapped_data:
641                 map_replace:
642                   - {get_param: ServiceConfigSettings}
643                   - values: {get_attr: [NetIpMap, net_ip_map]}
644             controller_extraconfig:
645               mapped_data:
646                 map_merge:
647                   - {get_param: controllerExtraConfig}
648                   - {get_param: ControllerExtraConfig}
649             extraconfig:
650               mapped_data: {get_param: ExtraConfig}
651             network:
652               mapped_data:
653                 net_ip_map: {get_attr: [NetIpMap, net_ip_map]}
654                 net_ip_uri_map: {get_attr: [NetIpMap, net_ip_uri_map]}
655             ceph:
656               mapped_data:
657                 ceph::profile::params::cluster_network: {get_input: ceph_cluster_network}
658                 ceph::profile::params::public_network: {get_input: ceph_public_network}
659                 ceph::profile::params::public_addr: {get_input: ceph_public_ip}
660             controller:
661               mapped_data: # data supplied directly to this deployment configuration, etc
662                 bootstack_nodeid: {get_input: bootstack_nodeid}
663
664                 # Pacemaker
665                 enable_fencing: {get_input: enable_fencing}
666                 enable_load_balancer: {get_input: enable_load_balancer}
667                 hacluster_pwd: {get_input: pcsd_password}
668                 corosync_ipv6: {get_input: corosync_ipv6}
669                 tripleo::fencing::config: {get_input: fencing_config}
670
671                 # Swift
672                 # FIXME: need to move proxy_local_net_ip into swift-proxy.yaml
673                 swift::proxy::proxy_local_net_ip: {get_input: swift_proxy_network}
674                 swift::storage::all::storage_local_net_ip: {get_input: swift_management_network}
675                 swift::swift_hash_path_suffix: {get_input: swift_hash_suffix}
676
677                 # Cinder
678                 tripleo::profile::base::cinder::volume::iscsi::cinder_iscsi_address: {get_input: cinder_iscsi_network}
679                 cinder::api::bind_host: {get_input: cinder_api_network}
680
681                 # Glance
682                 glance::api::bind_host: {get_input: glance_api_network}
683                 glance::registry::bind_host: {get_input: glance_registry_network}
684
685                 # Heat
686                 heat::api::bind_host: {get_input: heat_api_network}
687                 heat::api_cloudwatch::bind_host: {get_input: heat_api_network}
688                 heat::api_cfn::bind_host: {get_input: heat_api_network}
689                 heat::engine::auth_encryption_key: {get_input: heat_auth_encryption_key}
690
691                 # Keystone
692                 keystone::admin_bind_host: {get_input: keystone_admin_api_network}
693                 keystone::public_bind_host: {get_input: keystone_public_api_network}
694                 keystone::wsgi::apache::bind_host: {get_input: keystone_public_api_network}
695                 keystone::wsgi::apache::admin_bind_host: {get_input: keystone_admin_api_network}
696
697                 # Manila
698                 manila::api::bind_host: {get_input: manila_api_network}
699
700                 # MongoDB
701                 mongodb::server::bind_ip: {get_input: mongo_db_network}
702
703                 # MySQL
704                 admin_password: {get_input: admin_password}
705                 enable_galera: {get_input: enable_galera}
706                 mysql_innodb_buffer_pool_size: {get_input: mysql_innodb_buffer_pool_size}
707                 mysql_max_connections: {get_input: mysql_max_connections}
708                 mysql::server::root_password: {get_input: mysql_root_password}
709                 mysql_clustercheck_password: {get_input: mysql_clustercheck_password}
710                 mysql_cluster_name: {get_input: mysql_cluster_name}
711                 mysql_bind_host: {get_input: mysql_network}
712                 mysql_virtual_ip: {get_input: mysql_virtual_ip}
713
714                 # Neutron
715                 neutron::bind_host: {get_input: neutron_api_network}
716                 neutron::agents::ml2::ovs::local_ip: {get_input: neutron_local_ip}
717                 neutron::agents::metadata::metadata_ip: {get_input: neutron_api_network}
718
719                 # Aodh
720                 aodh::api::host: {get_input: aodh_api_network}
721                 aodh::wsgi::apache::bind_host: {get_input: aodh_api_network}
722
723                 # Ceilometer
724                 ceilometer::api::host: {get_input: ceilometer_api_network}
725                 snmpd_readonly_user_name: {get_input: snmpd_readonly_user_name}
726                 snmpd_readonly_user_password: {get_input: snmpd_readonly_user_password}
727
728                 # Gnocchi
729                 gnocchi::wsgi::apache::bind_host: {get_input: gnocchi_api_network}
730                 gnocchi::api::host: {get_input: gnocchi_api_network}
731                 gnocchi::api::keystone_auth_uri: {get_input: keystone_auth_uri}
732                 gnocchi::api::keystone_identity_uri: {get_input: keystone_identity_uri}
733                 gnocchi::storage::swift::swift_authurl: {get_input: keystone_auth_uri}
734
735                 # Nova
736                 nova::upgrade_level_compute: {get_input: upgrade_level_nova_compute}
737                 nova::use_ipv6: {get_input: nova_ipv6}
738                 nova::api::auth_uri: {get_input: keystone_auth_uri}
739                 nova::api::identity_uri: {get_input: keystone_identity_uri}
740                 nova::api::api_bind_address: {get_input: nova_api_network}
741                 nova::api::metadata_listen: {get_input: nova_metadata_network}
742                 nova::api::admin_password: {get_input: nova_password}
743                 nova::glance_api_servers: {get_input: glance_api_servers}
744                 nova::api::neutron_metadata_proxy_shared_secret: {get_input: neutron_metadata_proxy_shared_secret}
745                 nova::api::instance_name_template: {get_input: instance_name_template}
746                 nova::vncproxy::host: {get_input: nova_api_network}
747                 nova_enable_db_purge: {get_input: nova_enable_db_purge}
748
749                 # Horizon
750                 apache::mod::remoteip::proxy_ips: {get_input: horizon_subnet}
751                 apache::ip: {get_input: horizon_network}
752                 horizon::django_debug: {get_input: debug}
753                 horizon::secret_key: {get_input: horizon_secret}
754                 horizon::bind_address: {get_input: horizon_network}
755                 horizon::keystone_url: {get_input: keystone_auth_uri}
756
757                 # Sahara
758                 sahara::host: {get_input: sahara_api_network}
759
760                 # RabbitMQ
761                 rabbitmq::node_ip_address: {get_input: rabbitmq_network}
762                 rabbitmq::erlang_cookie: {get_input: rabbit_cookie}
763                 # Redis
764                 redis::bind: {get_input: redis_network}
765                 redis_vip: {get_input: redis_vip}
766                 # Firewall
767                 tripleo::firewall::manage_firewall: {get_input: manage_firewall}
768                 tripleo::firewall::purge_firewall_rules: {get_input: purge_firewall_rules}
769                 # Misc
770                 memcached_ipv6: {get_input: memcached_ipv6}
771                 memcached::listen_ip: {get_input: memcached_network}
772                 control_virtual_interface: {get_input: control_virtual_interface}
773                 public_virtual_interface: {get_input: public_virtual_interface}
774                 tripleo::keepalived::control_virtual_interface: {get_input: control_virtual_interface}
775                 tripleo::keepalived::public_virtual_interface: {get_input: public_virtual_interface}
776                 tripleo::haproxy::control_virtual_interface: {get_input: control_virtual_interface}
777                 tripleo::haproxy::public_virtual_interface: {get_input: public_virtual_interface}
778                 tripleo::haproxy::haproxy_log_address: {get_input: haproxy_log_address}
779                 tripleo::haproxy::service_certificate: {get_attr: [NodeTLSData, deployed_ssl_certificate_path]}
780                 tripleo::haproxy::haproxy_stats_user: {get_input: haproxy_stats_user}
781                 tripleo::haproxy::haproxy_stats_password: {get_input: haproxy_stats_password}
782                 tripleo::haproxy::redis_password: {get_input: redis_password}
783                 tripleo::packages::enable_install: {get_input: enable_package_install}
784                 tripleo::packages::enable_upgrade: {get_input: enable_package_upgrade}
785
786   # Hook for site-specific additional pre-deployment config, e.g extra hieradata
787   ControllerExtraConfigPre:
788     depends_on: ControllerDeployment
789     type: OS::TripleO::ControllerExtraConfigPre
790     properties:
791         server: {get_resource: Controller}
792
793   # Hook for site-specific additional pre-deployment config,
794   # applying to all nodes, e.g node registration/unregistration
795   NodeExtraConfig:
796     depends_on: [ControllerExtraConfigPre, NodeTLSData]
797     type: OS::TripleO::NodeExtraConfig
798     properties:
799         server: {get_resource: Controller}
800
801   UpdateConfig:
802     type: OS::TripleO::Tasks::PackageUpdate
803
804   UpdateDeployment:
805     type: OS::Heat::SoftwareDeployment
806     properties:
807       name: UpdateDeployment
808       config: {get_resource: UpdateConfig}
809       server: {get_resource: Controller}
810       input_values:
811         update_identifier:
812           get_param: UpdateIdentifier
813
814 outputs:
815   ip_address:
816     description: IP address of the server in the ctlplane network
817     value: {get_attr: [Controller, networks, ctlplane, 0]}
818   external_ip_address:
819     description: IP address of the server in the external network
820     value: {get_attr: [ExternalPort, ip_address]}
821   internal_api_ip_address:
822     description: IP address of the server in the internal_api network
823     value: {get_attr: [InternalApiPort, ip_address]}
824   storage_ip_address:
825     description: IP address of the server in the storage network
826     value: {get_attr: [StoragePort, ip_address]}
827   storage_mgmt_ip_address:
828     description: IP address of the server in the storage_mgmt network
829     value: {get_attr: [StorageMgmtPort, ip_address]}
830   tenant_ip_address:
831     description: IP address of the server in the tenant network
832     value: {get_attr: [TenantPort, ip_address]}
833   management_ip_address:
834     description: IP address of the server in the management network
835     value: {get_attr: [ManagementPort, ip_address]}
836   hostname:
837     description: Hostname of the server
838     value: {get_attr: [Controller, name]}
839   hosts_entry:
840     description: >
841       Server's IP address and hostname in the /etc/hosts format
842     value:
843       str_replace:
844         template: |
845           PRIMARYIP PRIMARYHOST.DOMAIN PRIMARYHOST
846           EXTERNALIP EXTERNALHOST.DOMAIN EXTERNALHOST
847           INTERNAL_APIIP INTERNAL_APIHOST.DOMAIN INTERNAL_APIHOST
848           STORAGEIP STORAGEHOST.DOMAIN STORAGEHOST
849           STORAGE_MGMTIP STORAGE_MGMTHOST.DOMAIN STORAGE_MGMTHOST
850           TENANTIP TENANTHOST.DOMAIN TENANTHOST
851           MANAGEMENTIP MANAGEMENTHOST.DOMAIN MANAGEMENTHOST
852         params:
853           PRIMARYIP: {get_attr: [NetIpMap, net_ip_map, {get_param: [ServiceNetMap, ControllerHostnameResolveNetwork]}]}
854           DOMAIN: {get_param: CloudDomain}
855           PRIMARYHOST: {get_attr: [Controller, name]}
856           EXTERNALIP: {get_attr: [ExternalPort, ip_address]}
857           EXTERNALHOST:
858             list_join:
859             - '.'
860             - - {get_attr: [Controller, name]}
861               - external
862           INTERNAL_APIIP: {get_attr: [InternalApiPort, ip_address]}
863           INTERNAL_APIHOST:
864             list_join:
865             - '.'
866             - - {get_attr: [Controller, name]}
867               - internalapi
868           STORAGEIP: {get_attr: [StoragePort, ip_address]}
869           STORAGEHOST:
870             list_join:
871             - '.'
872             - - {get_attr: [Controller, name]}
873               - storage
874           STORAGE_MGMTIP: {get_attr: [StorageMgmtPort, ip_address]}
875           STORAGE_MGMTHOST:
876             list_join:
877             - '.'
878             - - {get_attr: [Controller, name]}
879               - storagemgmt
880           TENANTIP: {get_attr: [TenantPort, ip_address]}
881           TENANTHOST:
882             list_join:
883             - '.'
884             - - {get_attr: [Controller, name]}
885               - tenant
886           MANAGEMENTIP: {get_attr: [ManagementPort, ip_address]}
887           MANAGEMENTHOST:
888             list_join:
889             - '.'
890             - - {get_attr: [Controller, name]}
891               - management
892   nova_server_resource:
893     description: Heat resource handle for the Nova compute server
894     value:
895       {get_resource: Controller}
896   swift_device:
897     description: Swift device formatted for swift-ring-builder
898     value:
899       str_replace:
900         template: 'r1z1-IP:%PORT%/d1'
901         params:
902           IP: {get_attr: [NetIpMap, net_ip_uri_map, {get_param: [ServiceNetMap, SwiftMgmtNetwork]}]}
903   swift_proxy_memcache:
904     description: Swift proxy-memcache value
905     value:
906       str_replace:
907         template: "IP:11211"
908         params:
909           IP: {get_attr: [NetIpMap, net_ip_uri_map, {get_param: [ServiceNetMap, MemcachedNetwork]}]}
910   tls_key_modulus_md5:
911     description: MD5 checksum of the TLS Key Modulus
912     value: {get_attr: [NodeTLSData, key_modulus_md5]}
913   tls_cert_modulus_md5:
914     description: MD5 checksum of the TLS Certificate Modulus
915     value: {get_attr: [NodeTLSData, cert_modulus_md5]}