use gnocchi devstack script

check to see if gnocchi enabled independently via enable_plugin.
if so, let it do it's thing.

Change-Id: Idabbf9b6e874875f8dd3bad52501966385823395
This commit is contained in:
gord chung 2017-06-14 21:50:54 +00:00 committed by gordon chung
parent 22e8481e70
commit 36a31ff3f5
1 changed files with 3 additions and 3 deletions

View File

@ -183,7 +183,7 @@ function ceilometer_create_accounts {
get_or_add_user_project_role "ResellerAdmin" "ceilometer" $SERVICE_PROJECT_NAME get_or_add_user_project_role "ResellerAdmin" "ceilometer" $SERVICE_PROJECT_NAME
fi fi
if [ "$CEILOMETER_BACKEND" == "gnocchi" ]; then if ! [[ $DEVSTACK_PLUGINS =~ 'gnocchi' ]] && [ "$CEILOMETER_BACKEND" == "gnocchi" ]; then
create_service_user "gnocchi" create_service_user "gnocchi"
local gnocchi_service=$(get_or_create_service "gnocchi" \ local gnocchi_service=$(get_or_create_service "gnocchi" \
"metric" "OpenStack Metric Service") "metric" "OpenStack Metric Service")
@ -432,7 +432,7 @@ function install_ceilometer {
_ceilometer_prepare_coordination _ceilometer_prepare_coordination
fi fi
[ "$CEILOMETER_BACKEND" = 'gnocchi' ] && install_gnocchi ! [[ $DEVSTACK_PLUGINS =~ 'gnocchi' ]] && [ "$CEILOMETER_BACKEND" = 'gnocchi' ] && install_gnocchi
if is_service_enabled ceilometer-api; then if is_service_enabled ceilometer-api; then
_ceilometer_prepare_storage_backend _ceilometer_prepare_storage_backend
@ -461,7 +461,7 @@ function install_ceilometerclient {
# start_ceilometer() - Start running processes, including screen # start_ceilometer() - Start running processes, including screen
function start_ceilometer { function start_ceilometer {
if [ "$CEILOMETER_BACKEND" = "gnocchi" ] ; then if ! [[ $DEVSTACK_PLUGINS =~ 'gnocchi' ]] && [ "$CEILOMETER_BACKEND" = "gnocchi" ] ; then
run_process gnocchi-api "$CEILOMETER_BIN_DIR/uwsgi --ini $GNOCCHI_UWSGI_FILE" "" run_process gnocchi-api "$CEILOMETER_BIN_DIR/uwsgi --ini $GNOCCHI_UWSGI_FILE" ""
run_process gnocchi-metricd "$CEILOMETER_BIN_DIR/gnocchi-metricd --config-file $GNOCCHI_CONF" run_process gnocchi-metricd "$CEILOMETER_BIN_DIR/gnocchi-metricd --config-file $GNOCCHI_CONF"
wait_for_service 30 "$(gnocchi_service_url)" wait_for_service 30 "$(gnocchi_service_url)"