summaryrefslogtreecommitdiffstats
path: root/ci/clean.sh
diff options
context:
space:
mode:
authorNarinder Gupta <narinder.gupta@canonical.com>2016-10-17 00:08:32 -0500
committerNarinder Gupta <narinder.gupta@canonical.com>2016-10-17 06:37:56 -0500
commit7ae91a059f2b498ebacc66440f5de21eea99033c (patch)
treee3113ebff9adc945155a4013b66629d70b45a17e /ci/clean.sh
parentf1dfc0776d32dea2a2fe7e2cb2b15b1836a6b666 (diff)
more changes needed for juju 2.0
Change-Id: I30a1703bdd0dbfc72d0a35c2bee39a1f1b57b52a Signed-off-by: Narinder Gupta <narinder.gupta@canonical.com>
Diffstat (limited to 'ci/clean.sh')
-rwxr-xr-xci/clean.sh5
1 files changed, 3 insertions, 2 deletions
diff --git a/ci/clean.sh b/ci/clean.sh
index 4c507b25..3c0a71e4 100755
--- a/ci/clean.sh
+++ b/ci/clean.sh
@@ -3,12 +3,13 @@
set -ex
if [ ! -d environments.yaml ]; then
- cp ~/joid_config/environments.yaml ./environments.yaml
+ cp ~/joid_config/environments.yaml ./environments.yaml || true
+ cp ~/.juju/environments.yaml ./environments.yaml || true
fi
jujuver=`juju --version`
-if [ "$jujuver" -ge "2" ]; then
+if [ "$jujuver" > "2" ]; then
controllername=`awk 'NR==1{print $2}' environments.yaml`
cloudname=`awk 'NR==1{print $2}' environments.yaml`
juju kill-controller $controllername --timeout 10s -y || true