update salt_master/master_hostname usage, add master_ip

Change-Id: Id818c796c1ca15f15593d897434d80f3220080fd
diff --git a/bootstrap.sh b/bootstrap.sh
index 627d721..90eebaf 100755
--- a/bootstrap.sh
+++ b/bootstrap.sh
@@ -73,7 +73,6 @@
 export DOMAIN=${DOMAIN:-bootstrap.local}
 
 # salt
-export SALT_MASTER=${SALT_MASTER:-127.0.0.1} # ip or fqdn
 export MINION_ID=${MINION_ID:-${HOSTNAME}.${DOMAIN}}
 export MASTER_HOSTNAME=${MASTER_HOSTNAME:-${HOSTNAME}.${DOMAIN}}
 
@@ -306,13 +305,13 @@
 	- cluster.${CLUSTER_NAME}.infra.config
 	parameters:
 	  _param:
-	    single_address: $SALT_MASTER
-	    salt_master_host: $SALT_MASTER
+	    single_address: ${MASTER_IP:-$MASTER_HOSTNAME}
+	    salt_master_host: ${MASTER_IP:-$MASTER_HOSTNAME}
 	    salt_master_base_environment: $SALT_ENV
 	    salt_formula_branch: ${SALT_FORMULAS_BRANCH:-master}
 	    reclass_data_revision: ${RECLASS_BRANCH:-master}
 	    reclass_data_repository: "$RECLASS_ADDRESS"
-	    reclass_config_master: $SALT_MASTER
+	    reclass_config_master: ${MASTER_IP:-$MASTER_HOSTNAME}
 	    linux_system_codename: ${DISTRIB_CODENAME}
 	    cluster_name: ${CLUSTER_NAME}
 	    cluster_domain: ${DOMAIN:-$CLUSTER_NAME.local}
@@ -353,7 +352,7 @@
 {
   [ ! -d /etc/salt/minion.d ] && mkdir -p /etc/salt/minion.d
   cat <<-EOF > /etc/salt/minion.d/minion.conf
-	master: $SALT_MASTER
+	master: ${MASTER_IP:-$MASTER_HOSTNAME}
 	id: $MINION_ID
 	EOF
 }
@@ -438,8 +437,6 @@
 install_salt_minion_pkg()
 {
 
-    configure_pkg_repo
-
     echo -e "\nInstalling salt minion ...\n"
 
     case $PLATFORM_FAMILY in
@@ -548,7 +545,7 @@
     pgrep salt-master | sed /$$/d | xargs --no-run-if-empty -i{} $SUDO kill -9 {}
     pkill -9 salt-minion
     test -e ${SCRIPTS}/.salt-master-setup.sh.passed || {
-        export SALT_MASTER=localhost
+        export MASTER_IP=localhost
         export MINION_ID=${MASTER_HOSTNAME}
         if ! [[ $DEBUG =~ ^(True|true|1|yes)$ ]]; then
           SALT_MASTER_SETUP_OUTPUT='/dev/stdout'