Fix uninstall bug that leaves Juju controller running 44/7644/1
authorAdam Israel <adam.israel@canonical.com>
Tue, 11 Jun 2019 14:28:43 +0000 (10:28 -0400)
committerAdam Israel <adam.israel@canonical.com>
Tue, 11 Jun 2019 14:32:29 +0000 (10:32 -0400)
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>
installers/full_install_osm.sh

index 40cbfda..96ffdbe 100755 (executable)
@@ -180,7 +180,7 @@ EONG
         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"