1 heat_template_version: pike
4 RabbitMQ service configured with Puppet
9 description: Dictionary packing service data
13 description: Mapping of service_name -> network name. Typically set
14 via parameter_defaults in the resource registry. This
15 mapping overrides those in ServiceNetMapDefaults.
22 description: Role name on which the service is applied
26 description: Parameters specific to the role
30 description: Mapping of service endpoint -> protocol. Typically set
31 via parameter_defaults in the resource registry.
35 description: The username for RabbitMQ
38 description: The password for RabbitMQ
43 description: Configures RabbitMQ FD limit
47 description: Enable IPv6 in RabbitMQ
55 The number of HA queues to be configured in rabbit. The default is -1 which
56 translates to "ha-mode all". The special value 0 will be automatically
57 overridden to CEIL(N/2) where N is the number of nodes running rabbitmq.
60 MonitoringSubscriptionRabbitmq:
61 default: 'overcloud-rabbitmq'
68 internal_tls_enabled: {equals: [{get_param: EnableInternalTLS}, true]}
72 description: Role data for the RabbitMQ role.
74 service_name: rabbitmq
75 monitoring_subscription: {get_param: MonitoringSubscriptionRabbitmq}
79 rabbitmq::file_limit: {get_param: RabbitFDLimit}
80 rabbitmq::default_user: {get_param: RabbitUserName}
81 rabbitmq::default_pass: {get_param: RabbitPassword}
82 rabbit_ipv6: {get_param: RabbitIPv6}
83 tripleo.rabbitmq.firewall_rules:
89 rabbitmq::delete_guest_user: false
90 rabbitmq::wipe_db_on_cookie_change: true
91 rabbitmq::port: '5672'
92 rabbitmq::package_provider: yum
93 rabbitmq::package_source: undef
94 rabbitmq::repos_ensure: false
95 rabbitmq::tcp_keepalive: true
99 RABBITMQ_NODENAME: "rabbit@%{::hostname}"
100 RABBITMQ_SERVER_ERL_ARGS: '"+K true +P 1048576 -kernel inet_default_connect_options [{nodelay,true},{raw,6,18,<<15000:64/native>>}] -kernel inet_default_listen_options [{raw,6,18,<<15000:64/native>>}]"'
101 'export ERL_EPMD_ADDRESS': "%{hiera('rabbitmq::interface')}"
102 rabbitmq_kernel_variables:
103 inet_dist_listen_min: '25672'
104 inet_dist_listen_max: '25672'
105 rabbitmq_config_variables:
106 cluster_partition_handling: 'pause_minority'
107 queue_master_locator: '<<"min-masters">>'
109 rabbitmq::erlang_cookie:
111 expression: $.data.passwords.where($ != '').first()
114 - {get_param: RabbitCookie}
115 - {get_param: [DefaultPasswords, rabbit_cookie]}
116 # NOTE: bind IP is found in Heat replacing the network name with the
117 # local node IP for the given network; replacement examples
118 # (eg. for internal_api):
120 # internal_api_uri -> [IP]
121 # internal_api_subnet - > IP/CIDR
122 rabbitmq::interface: {get_param: [ServiceNetMap, RabbitmqNetwork]}
123 rabbitmq::nr_ha_queues: {get_param: RabbitHAQueues}
124 rabbitmq::ssl: {get_param: EnableInternalTLS}
125 rabbitmq::ssl_port: '5672'
126 rabbitmq::ssl_depth: 1
127 rabbitmq::ssl_only: {get_param: EnableInternalTLS}
128 rabbitmq::ssl_interface: {get_param: [ServiceNetMap, RabbitmqNetwork]}
129 # TODO(jaosorior): Remove this once we set a proper default in
131 tripleo::profile::base::rabbitmq::enable_internal_tls: {get_param: EnableInternalTLS}
134 - internal_tls_enabled
135 - generate_service_certificates: true
136 tripleo::profile::base::rabbitmq::certificate_specs:
137 service_certificate: '/etc/pki/tls/certs/rabbitmq.crt'
138 service_key: '/etc/pki/tls/private/rabbitmq.key'
141 template: "%{hiera('fqdn_NETWORK')}"
143 NETWORK: {get_param: [ServiceNetMap, RabbitmqNetwork]}
146 template: "rabbitmq/%{hiera('fqdn_NETWORK')}"
148 NETWORK: {get_param: [ServiceNetMap, RabbitmqNetwork]}
151 include ::tripleo::profile::base::rabbitmq
153 - name: Stop rabbitmq service
155 service: name=rabbitmq-server state=stopped
156 - name: Start rabbitmq service
158 service: name=rabbitmq-server state=started
161 - internal_tls_enabled
164 network: {get_param: [ServiceNetMap, RabbitmqNetwork]}