update
This commit is contained in:
@@ -59,7 +59,7 @@ DELSITE(){
|
||||
# echo -e "${idsCL[Green]}Done${idsCL[Default]}"
|
||||
|
||||
# nid=1
|
||||
# for nip in "${WEB_HOSTS[@]}"; do
|
||||
# for nip in "${NM_HOSTS['WEB'][@]}"; do
|
||||
# if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) == *"${nip}"* ]]; then
|
||||
# nip='localhost '
|
||||
# NCMD=''
|
||||
@@ -110,7 +110,7 @@ DELSITES(){
|
||||
echo -e "${idsCL[Red]}Select a site to delete...${idsCL[Default]}"
|
||||
DIVIDER true
|
||||
sid=1
|
||||
# filels="( $(ssh root@${LB_HOSTS[0]} ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
# filels="( $(ssh root@${NM_HOSTS['LB'][0]} ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
filels="( $(ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
# IFS='\n'
|
||||
for siteconf in $filels; do
|
||||
@@ -174,7 +174,7 @@ LISTSITES(){
|
||||
echo
|
||||
echo -e "${idsCL[Red]}NGINX Site Config...${idsCL[Default]}"
|
||||
DIVIDER true
|
||||
# filels="( $(ssh root@${LB_HOSTS[0]} ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
# filels="( $(ssh root@${NM_HOSTS['LB'][0]} ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
filels="( $(ls ${NM_NGINXPATH}/sites-enabled/*) )"
|
||||
for siteconf in $filels; do
|
||||
if [ ${siteconf:0:1} == '/' ]; then
|
||||
@@ -418,7 +418,7 @@ NEWSITE(){
|
||||
|
||||
sudo -u www-data mkdir -p /var/www/${MAIN_SITE}/{public_html,nginx_logs}
|
||||
# echo -en "${idsCL[LightYellow]}Waiting for folder replication across the webserver nodes... ${idsCL[Default]}"
|
||||
# for nip in "${WEB_HOSTS[@]}"; do
|
||||
# for nip in "${NM_HOSTS['WEB'][@]}"; do
|
||||
# checkhost=$(CHECK_HOST ${nip})
|
||||
# if [ "${checkhost}" != "false" ]; then
|
||||
# if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) != *"${nip}"* ]]; then
|
||||
@@ -478,7 +478,7 @@ NEWSITE(){
|
||||
else
|
||||
# echo
|
||||
# echo -en "${idsCL[LightYellow]}Verifying '${NEW_SITE}' replication across the nodes... ${idsCL[Default]}"
|
||||
# for nip in "${LB_HOSTS[@]}"; do
|
||||
# for nip in "${NM_HOSTS['LB'][@]}"; do
|
||||
# checkhost=$(CHECK_HOST ${nip})
|
||||
# if [ "${checkhost}" != "false" ]; then
|
||||
# if [[ $(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1) != *"${nip}"* ]]; then
|
||||
|
||||
Reference in New Issue
Block a user