Compartmentalizing RabbitMQ
Presently all services use the single root virtual host within RabbitMQ and while this is “OK” for small to mid sized deployments however it would be better to divide services into logical resource groups within RabbitMQ which will bring with it additional security. This change set provides OSAD better compartmentalization of consumer services that use RabbitMQ. UpgradeImpact DocImpact Change-Id: I6f9d07522faf133f3c1c84a5b9046a55d5789e52 Implements: blueprint compartmentalize-rabbitmq
This commit is contained in:
parent
30c2fb2e95
commit
2c27b7771e
@ -78,6 +78,10 @@ keystone_database_min_pool_size: 5
|
|||||||
keystone_database_max_pool_size: 120
|
keystone_database_max_pool_size: 120
|
||||||
keystone_database_pool_timeout: 30
|
keystone_database_pool_timeout: 30
|
||||||
|
|
||||||
|
## RabbitMQ info
|
||||||
|
keystone_rabbitmq_userid: keystone
|
||||||
|
keystone_rabbitmq_vhost: /keystone
|
||||||
|
|
||||||
## Role info
|
## Role info
|
||||||
keystone_role_name: admin
|
keystone_role_name: admin
|
||||||
keystone_default_role_name: _member_
|
keystone_default_role_name: _member_
|
||||||
|
37
tasks/keystone_messaging_setup.yml
Normal file
37
tasks/keystone_messaging_setup.yml
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
---
|
||||||
|
# Copyright 2014, Rackspace US, Inc.
|
||||||
|
#
|
||||||
|
# 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.
|
||||||
|
|
||||||
|
- name: Ensure Rabbitmq vhost
|
||||||
|
rabbitmq_vhost:
|
||||||
|
name: "{{ keystone_rabbitmq_vhost }}"
|
||||||
|
state: "present"
|
||||||
|
delegate_to: "{{ groups['rabbitmq_all'][0] }}"
|
||||||
|
tags:
|
||||||
|
- keystone-rabbitmq
|
||||||
|
- keystone-rabbitmq-vhost
|
||||||
|
|
||||||
|
- name: Ensure rabbitmq user
|
||||||
|
rabbitmq_user:
|
||||||
|
user: "{{ keystone_rabbitmq_userid }}"
|
||||||
|
password: "{{ keystone_rabbitmq_password }}"
|
||||||
|
vhost: "{{ keystone_rabbitmq_vhost }}"
|
||||||
|
configure_priv: ".*"
|
||||||
|
read_priv: ".*"
|
||||||
|
write_priv: ".*"
|
||||||
|
state: "present"
|
||||||
|
delegate_to: "{{ groups['rabbitmq_all'][0] }}"
|
||||||
|
tags:
|
||||||
|
- keystone-rabbitmq
|
||||||
|
- keystone-rabbitmq-user
|
@ -106,3 +106,7 @@
|
|||||||
tags:
|
tags:
|
||||||
- keystone-dirs
|
- keystone-dirs
|
||||||
- keystone-logs
|
- keystone-logs
|
||||||
|
|
||||||
|
- include: keystone_messaging_setup.yml
|
||||||
|
when: >
|
||||||
|
inventory_hostname == groups['keystone_all'][0]
|
||||||
|
@ -134,9 +134,11 @@ admin_port = {{ keystone_admin_port }}
|
|||||||
public_port = {{ keystone_service_port }}
|
public_port = {{ keystone_service_port }}
|
||||||
|
|
||||||
[oslo_messaging_rabbit]
|
[oslo_messaging_rabbit]
|
||||||
|
rabbit_port = {{ rabbitmq_port }}
|
||||||
|
rabbit_userid = {{ keystone_rabbitmq_userid }}
|
||||||
|
rabbit_password = {{ keystone_rabbitmq_password }}
|
||||||
|
rabbit_virtual_host = {{ keystone_rabbitmq_vhost }}
|
||||||
rabbit_hosts = {{ rabbitmq_servers }}
|
rabbit_hosts = {{ rabbitmq_servers }}
|
||||||
rabbit_userid = {{ rabbitmq_userid }}
|
|
||||||
rabbit_password = {{ rabbitmq_password }}
|
|
||||||
|
|
||||||
{% if keystone_sp is defined %}
|
{% if keystone_sp is defined %}
|
||||||
[federation]
|
[federation]
|
||||||
@ -147,3 +149,4 @@ trusted_dashboard = {{ item }}
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user