fix bugs in install.sh

Change-Id: I9461be7ee99c81d9691a216ecd00f6d432ef54ec
This commit is contained in:
Xicheng Chang 2016-08-25 19:54:18 -04:00
parent af4c49294c
commit 2b2ecce938
1 changed files with 7 additions and 7 deletions

View File

@ -200,12 +200,12 @@ fi
# Install figlet
sudo yum -y install figlet >& /dev/null
if [[ "$?" != "0" ]]; then
echo "failed to install figlet"
exit 1
else
echo "figlet is installed"
fi
# if [[ "$?" != "0" ]]; then
# echo "failed to install figlet"
# exit 1
# else
# echo "figlet is installed"
# fi
figlet -ctf slant Compass Installer
while [ $1 ]; do
@ -270,7 +270,7 @@ fi
export NIC=${NIC:-"eth1"}
export IPADDR=${IPADDR:-$(sudo ifconfig ${NIC} | awk '($1=="inet"){print $2}')}
export IPADDR=${IPADDR:-"10.1.0.15"}
export NETMASK=${NETMASK:-$(sudo ifconfig ${NIC} | awk '($3="netmask"){print $4}')}
export NETMASK=${NETMASK:-$(sudo ifconfig ${NIC} | awk '($3=="netmask"){print $4}')}
export NETMASK=${NETMASK:-"255.255.255.0"}
sudo ifconfig ${NIC} ${IPADDR} netmask ${NETMASK} up