Browse code

Setup AMQP properly for glance-registry

As we integrated OSprofiler with Glance:
https://review.openstack.org/#/c/105635/

glance-registry service started using notification API so it requires
proper seted up AMQP.

Change-Id: I0c4bb8a10960ed3ee06b67a209703d7ee81cf1ca

Boris Pavlovic authored on 2014/08/14 00:18:56
Showing 1 changed files
... ...
@@ -96,6 +96,10 @@ function configure_glance {
96 96
     iniset $GLANCE_REGISTRY_CONF keystone_authtoken admin_user glance
97 97
     iniset $GLANCE_REGISTRY_CONF keystone_authtoken admin_password $SERVICE_PASSWORD
98 98
     iniset $GLANCE_REGISTRY_CONF keystone_authtoken signing_dir $GLANCE_AUTH_CACHE_DIR/registry
99
+    if is_service_enabled qpid || [ -n "$RABBIT_HOST" ] && [ -n "$RABBIT_PASSWORD" ]; then
100
+        iniset $GLANCE_REGISTRY_CONF DEFAULT notification_driver messaging
101
+    fi
102
+    iniset_rpc_backend glance $GLANCE_REGISTRY_CONF DEFAULT
99 103
 
100 104
     cp $GLANCE_DIR/etc/glance-api.conf $GLANCE_API_CONF
101 105
     iniset $GLANCE_API_CONF DEFAULT debug $ENABLE_DEBUG_LOG_LEVEL