From 933b73f18f9cf4098df8613663c79fad5624558d Mon Sep 17 00:00:00 2001 From: "Donovan Francesco (drifterza)" Date: Fri, 4 Nov 2016 14:03:50 +0200 Subject: [PATCH] Adding support for Designate notifications. - This patch is for initial work on integrating Designate to our integrated gates. - Adding nova_designate_enabled option. - Adding oslo_messaging_notifications stanza. Change-Id: I55346e338feb9e4acd376988b664d08c286e1605 --- defaults/main.yml | 4 ++++ templates/nova.conf.j2 | 11 ++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/defaults/main.yml b/defaults/main.yml index c1b0b08f..8666b629 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -13,6 +13,10 @@ # See the License for the specific language governing permissions and # limitations under the License. +# Enable/Disable designate configurations +nova_designate_enabled: False +# Notification topics for designate. +nova_notifications_designate: notifications_designate # Enable/Disable ceilometer configurations nova_ceilometer_enabled: False diff --git a/templates/nova.conf.j2 b/templates/nova.conf.j2 index 27b1ecf3..e6325082 100644 --- a/templates/nova.conf.j2 +++ b/templates/nova.conf.j2 @@ -126,8 +126,17 @@ instance_usage_audit_period = hour notify_on_state_change = vm_and_task_state {% endif %} -{% if nova_ceilometer_enabled %} +# Notifications +{% if nova_ceilometer_enabled or nova_designate_enabled %} [oslo_messaging_notifications] +{% set notification_topics = [] %} +{% if neutron_ceilometer_enabled %} +{% set _ = notification_topics.append('notifications') %} +{% endif %} +{% if neutron_designate_enabled %} +{% set _ = notification_topics.append(nova_notifications_designate) %} +{% endif %} +notification_topics = {{ notification_topics | join(',') }} driver = messagingv2 transport_url = rabbit://{% for host in nova_rabbitmq_telemetry_servers.split(',') %}{{ nova_rabbitmq_telemetry_userid }}:{{ nova_rabbitmq_telemetry_password }}@{{ host }}:{{ nova_rabbitmq_telemetry_port }}{% if not loop.last %},{% else %}/{{ nova_rabbitmq_telemetry_vhost }}{% endif %}{% endfor %} {% endif %}