Use username and password from "os" in nodes.json
[icn.git] / env / metal3 / 01_install_package.sh
index 56b65d3..485fd18 100755 (executable)
@@ -1,5 +1,5 @@
 #!/usr/bin/env bash
-set -ex
+set -eux -o pipefail
 
 LIBDIR="$(dirname "$PWD")"
 
@@ -46,7 +46,8 @@ function install_ironic_packages {
     python-netaddr \
     python-openstackclient \
     unzip \
-    genisoimage
+    genisoimage \
+    whois
 
     if [ "$1" == "offline" ]; then
     pip install --no-index
@@ -112,9 +113,10 @@ install() {
     #install_kubernetes_packages $1
 }
 
-if ["$1" == "-o"]; then
+if [ "$#" -eq 0 ]; then
+    install online
+elif [ "$1" == "-o" ]; then
     install offline
-    exit 0
+else
+    exit 1
 fi
-
-install