diff --git a/lib/cinder b/lib/cinder index 49ad4afe04..adcc52c6df 100644 --- a/lib/cinder +++ b/lib/cinder @@ -104,11 +104,16 @@ function configure_cinder() { iniset $CINDER_CONF DEFAULT volume_name_template ${VOLUME_NAME_PREFIX}%s iniset $CINDER_CONF DEFAULT iscsi_helper tgtadm iniset $CINDER_CONF DEFAULT sql_connection $BASE_SQL_CONN/cinder?charset=utf8 - iniset $CINDER_CONF DEFAULT rabbit_host $RABBIT_HOST - iniset $CINDER_CONF DEFAULT rabbit_password $RABBIT_PASSWORD iniset $CINDER_CONF DEFAULT api_paste_config $CINDER_API_PASTE_INI iniset $CINDER_CONF DEFAULT root_helper "sudo ${CINDER_ROOTWRAP}" + if is_service_enabled qpid ; then + iniset $CINDER_CONF DEFAULT rpc_backend cinder.openstack.common.rpc.impl_qpid + elif [ -n "$RABBIT_HOST" ] && [ -n "$RABBIT_PASSWORD" ]; then + iniset $CINDER_CONF DEFAULT rabbit_host $RABBIT_HOST + iniset $CINDER_CONF DEFAULT rabbit_password $RABBIT_PASSWORD + fi + } # init_cinder() - Initialize database and volume group