Add regex search for '-' in juju controller name 83/6483/2
authorMike Marchetti <mmarchetti@sandvine.com>
Thu, 13 Sep 2018 19:35:42 +0000 (15:35 -0400)
committermarchettim <mmarchetti@sandvine.com>
Thu, 13 Sep 2018 19:36:20 +0000 (20:36 +0100)
Change-Id: Ibd954a88ec2907b545db6847dfb1b39232d709ee
Signed-off-by: Mike Marchetti <mmarchetti@sandvine.com>
installers/full_install_osm.sh

index 60a99e3..0a14e9d 100755 (executable)
@@ -84,7 +84,7 @@ function uninstall(){
 function parse_juju_password {
    password_file="${HOME}/.local/share/juju/accounts.yaml"
    local controller_name=$1
-   local s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034')
+   local s='[[:space:]]*' w='[a-zA-Z0-9_-]*' fs=$(echo @|tr @ '\034')
    sed -ne "s|^\($s\):|\1|" \
         -e "s|^\($s\)\($w\)$s:$s[\"']\(.*\)[\"']$s\$|\1$fs\2$fs\3|p" \
         -e "s|^\($s\)\($w\)$s:$s\(.*\)$s\$|\1$fs\2$fs\3|p" $password_file |