From 31ca5f00f374eaef24c48bb9fedfebc11a2d068c Mon Sep 17 00:00:00 2001 From: Eyal Date: Thu, 11 Apr 2019 10:20:35 +0300 Subject: [PATCH] move panel files to local/enabled * use HORIZON_DIR env * move VITRAGE_DASHBOARD_DIR to settings Change-Id: Ic234a7054ffd5229a43cf46a4fbf9dd06e222672 --- devstack/plugin.sh | 13 +++++++------ devstack/settings | 4 +++- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index 70061cd..dd415c6 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -1,14 +1,13 @@ #!/usr/bin/env bash # plugin.sh - DevStack plugin.sh dispatch script vitrage-dashboard -VITRAGE_DASHBOARD_DIR=$(cd $(dirname $BASH_SOURCE)/.. && pwd) function install_vitrage_dashboard { setup_develop ${VITRAGE_DASHBOARD_DIR} } function configure_vitrage_dashboard { - cp -a ${VITRAGE_DASHBOARD_DIR}/vitrage_dashboard/enabled/* ${DEST}/horizon/openstack_dashboard/enabled/ + cp -a ${VITRAGE_DASHBOARD_DIR}/vitrage_dashboard/enabled/* ${HORIZON_DIR}/openstack_dashboard/local/enabled/ } function init_vitrage_dashboard { @@ -48,9 +47,11 @@ if is_service_enabled vitrage-dashboard; then fi if [[ "$1" == "clean" ]]; then - # Remove state and transient data - # Remember clean.sh first calls unstack.sh - # no-op - : + rm -f ${HORIZON_DIR}/openstack_dashboard/local/enabled/_40* + rm -f ${HORIZON_DIR}/openstack_dashboard/local/enabled/_41* + + # for backward computability + rm -f ${HORIZON_DIR}/openstack_dashboard/enabled/_40* + rm -f ${HORIZON_DIR}/openstack_dashboard/enabled/_41* fi fi diff --git a/devstack/settings b/devstack/settings index 9d0318e..a61654e 100644 --- a/devstack/settings +++ b/devstack/settings @@ -1,2 +1,4 @@ # settings file for vitrage-dashboard plugin -enable_service vitrage-dashboard \ No newline at end of file +enable_service vitrage-dashboard + +VITRAGE_DASHBOARD_DIR=$DEST/vitrage-dashboard \ No newline at end of file