update install.sh and confs

Change-Id: Ic7f0bb6f1bfd1b2a7dbfe0c90c85f929b1f907f5
This commit is contained in:
Xicheng Chang 2016-07-06 20:39:59 -04:00
parent 8e5525aeb6
commit 250bd47366
4 changed files with 27 additions and 25 deletions

View File

@ -129,13 +129,13 @@ else
echo "compassed service is refreshed" echo "compassed service is refreshed"
fi fi
sudo systemctl status httpd.service # sudo systemctl status httpd.service
if [[ "$?" != "0" ]]; then # if [[ "$?" != "0" ]]; then
echo "httpd is not started" # echo "httpd is not started"
exit 1 # exit 1
else # else
echo "httpd has already started" # echo "httpd has already started"
fi # fi
sudo systemctl status redis.service |grep running sudo systemctl status redis.service |grep running
if [[ "$?" != "0" ]]; then if [[ "$?" != "0" ]]; then
@ -145,11 +145,11 @@ else
echo "redis has already started" echo "redis has already started"
fi fi
sudo systemctl status mysql.service |grep running # sudo systemctl status mysql.service |grep running
if [[ "$?" != "0" ]]; then # if [[ "$?" != "0" ]]; then
echo "mysqld is not started" # echo "mysqld is not started"
exit 1 # exit 1
fi # fi
sudo systemctl status compass-celeryd.service |grep running sudo systemctl status compass-celeryd.service |grep running
if [[ "$?" != "0" ]]; then if [[ "$?" != "0" ]]; then
@ -159,13 +159,13 @@ else
echo "compass-celeryd has already started" echo "compass-celeryd has already started"
fi fi
sudo systemctl status compass-progress-updated.service |grep running # sudo systemctl status compass-progress-updated.service |grep running
if [[ "$?" != "0" ]]; then # if [[ "$?" != "0" ]]; then
echo "compass-progress-updated is not started" # echo "compass-progress-updated is not started"
exit 1 # exit 1
else #else
echo "compass-progress-updated has already started" # echo "compass-progress-updated has already started"
fi #fi
sleep 10 sleep 10
#compass check #compass check

View File

@ -41,7 +41,7 @@ export OPTION_ROUTER="10.1.0.15"
export IP_START="10.1.0.100" export IP_START="10.1.0.100"
export IP_END="10.1.0.200" export IP_END="10.1.0.200"
# TFTP server's IP address(Default: Management Interface/eth0 IP) # TFTP server's IP address(Default: Management Interface/eth0 IP)
export NEXTSERVER="10.1.10.15" export NEXTSERVER="10.1.0.15"
# The machines MAC list. it must be filled, any space or null is wrong in quotes: # The machines MAC list. it must be filled, any space or null is wrong in quotes:
export switch_IP="127.0.0.1" export switch_IP="127.0.0.1"

View File

@ -88,7 +88,7 @@ set_iptables()
sudo rpm -qa | grep iptables-services sudo rpm -qa | grep iptables-services
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
sudo yum --enablerepo=compass_install --nogpgcheck -y install iptables-services sudo yum -y install iptables-services
fi fi
sudo /bin/systemctl status iptables.service sudo /bin/systemctl status iptables.service
@ -220,7 +220,7 @@ done
yum update -y yum update -y
sudo rpm -qa | grep net-tools sudo rpm -qa | grep net-tools
if [ $? -ne 0 ];then if [ $? -ne 0 ];then
yum --enablerepo=compass_install --nogpgcheck -y install net-tools yum -y install net-tools
fi fi
# check the correct format of ip variables # check the correct format of ip variables

View File

@ -16,6 +16,8 @@ exit 1
fi fi
echo "Register suceeded, your password is $password, please remember your password at all times." echo "Register suceeded, your password is $password, please remember your password at all times."
sed -i 's/^CELERY_DEFAULT_QUEUE.*/CELERY_DEFAULT_QUEUE = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig sed -i 's/^CELERY_DEFAULT_QUEUE.*/CELERY_DEFAULT_QUEUE = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig
sed -i 's/^CELERY_DEFAULT_EXCHANGE.*/CELERY_DEFAULT_EXCHANGE = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig sed -i 's/^CELERY_DEFAULT_EXCHANGE.*/CELERY_DEFAULT_EXCHANGE = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig
sed -i 's/^CELERY_DEFAULT_ROUTING_KEY.*/CELERY_DEFAULT_ROUTING_KEY = '"${USER_EMAIL}"'/g' /etc/compass/celeryconfig sed -i 's/^CELERY_DEFAULT_ROUTING_KEY.*/CELERY_DEFAULT_ROUTING_KEY = \"'"${USER_EMAIL}"'\"/g' /etc/compass/celeryconfig
systemctl restart compass-celeryd.service