From cfce054e8c2048259261fbce8b54830ee832d765 Mon Sep 17 00:00:00 2001 From: Sergey Murashov Date: Tue, 5 Aug 2014 16:42:33 +0400 Subject: [PATCH] Add cleanup method in devstack scripts Add cleanup method in devstack scripts which remove /tmp/keystone-signing-muranoapi Change-Id: Ie2a35c0c8ee99434aaed39e3da055785cb78ca3c Closes-bug: #1346400 --- contrib/devstack/extras.d/70-murano.sh | 1 + contrib/devstack/lib/murano | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/contrib/devstack/extras.d/70-murano.sh b/contrib/devstack/extras.d/70-murano.sh index 0b19a537..9ff3cd57 100644 --- a/contrib/devstack/extras.d/70-murano.sh +++ b/contrib/devstack/extras.d/70-murano.sh @@ -31,5 +31,6 @@ if is_service_enabled murano; then if [[ "$1" == "unstack" ]]; then stop_murano + cleanup_murano fi fi diff --git a/contrib/devstack/lib/murano b/contrib/devstack/lib/murano index b760d617..e3562345 100644 --- a/contrib/devstack/lib/murano +++ b/contrib/devstack/lib/murano @@ -41,6 +41,8 @@ MURANO_SERVICE_PROTOCOL=${MURANO_SERVICE_PROTOCOL:-$SERVICE_PROTOCOL} MURANO_ADMIN_USER=${MURANO_ADMIN_USER:-murano} +MURANO_KEYSTONE_SIGNING_DIR=${MURANO_KEYSTONE_SIGNING_DIR:-/tmp/keystone-signing-muranoapi} + # MURANO_RABBIT_VHOST allows to specify a separate virtual host for Murano services. # This is not required if all OpenStack services are deployed by devstack scripts # on a single node. In this case '/' virtual host (which is the default) is enough. @@ -137,6 +139,8 @@ function configure_murano { cp $MURANO_DIR/etc/murano/murano-paste.ini $MURANO_CONF_DIR cp $MURANO_DIR/etc/murano/policy.json $MURANO_POLICY_FILE + cleanup_murano + iniset $MURANO_CONF_FILE DEFAULT debug $MURANO_DEBUG iniset $MURANO_CONF_FILE DEFAULT use_syslog $SYSLOG @@ -212,6 +216,11 @@ function stop_murano() { screen -S $SCREEN_NAME -p murano-engine -X kill } +function cleanup_murano() { + + # Cleanup keystone signing dir + sudo rm -rf $MURANO_KEYSTONE_SIGNING_DIR +} # Restore xtrace $XTRACE