# # Copyright (C) 2013 eNovance SAS # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. # # RabbitMQ node # class os_messaging_server( $rabbit_names = $os_params::rabbit_names, $rabbit_password = $os_params::rabbit_password ){ class { 'rabbitmq::server': delete_guest_user => true, config_cluster => false, # true > Broken on RHEL/CentOS cluster_disk_nodes => $rabbit_names, wipe_db_on_cookie_change => true, } rabbitmq_vhost { '/': provider => 'rabbitmqctl', require => Class['rabbitmq::server'], } rabbitmq_user { ['nova', 'glance', 'neutron', 'cinder', 'ceilometer', 'heat']: admin => true, password => $rabbit_password, provider => 'rabbitmqctl', require => Class['rabbitmq::server'] } rabbitmq_user_permissions {[ 'nova@/', 'glance@/', 'neutron@/', 'cinder@/', 'ceilometer@/', 'heat@/', ]: configure_permission => '.*', write_permission => '.*', read_permission => '.*', provider => 'rabbitmqctl', } }