Fix uninstall bug that leaves Juju controller running
During uninstall, the Juju controller was not being destroyed when there
are active models. The `juju destroy-controller` command requires the
additional flag `--destroy-all-models`.
Change-Id: Ie5e3590027907ada08c6e6b2951a6f1ef64d41bf
Signed-off-by: Adam Israel <adam.israel@canonical.com>
diff --git a/installers/full_install_osm.sh b/installers/full_install_osm.sh
index 40cbfda..96ffdbe 100755
--- a/installers/full_install_osm.sh
+++ b/installers/full_install_osm.sh
@@ -180,7 +180,7 @@
remove_network $OSM_STACK_NAME
echo "Removing $OSM_DOCKER_WORK_DIR"
$WORKDIR_SUDO rm -rf $OSM_DOCKER_WORK_DIR
- sg lxd -c "juju destroy-controller --yes $OSM_STACK_NAME"
+ sg lxd -c "juju destroy-controller --destroy-all-models --yes $OSM_STACK_NAME"
fi
echo "Some docker images will be kept in case they are used by other docker stacks"
echo "To remove them, just run 'docker image prune' in a terminal"