Update nodemgmt-scripts.sh
This commit is contained in:
@@ -65,6 +65,21 @@ MAIN_MENU() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
|
service)
|
||||||
|
if [ "$3" = "nginx" ]; then SER='NGINX';
|
||||||
|
elif[ "$3" = "haproxy" ]; then SER='HAProxy';
|
||||||
|
elif[ "$3" = "gogs" ]; then SER='Gogs'
|
||||||
|
fi
|
||||||
|
if [ "$2" = "start" ]; then STA='Starting';
|
||||||
|
elif[ "$3" = "stop" ]; then STA='Stopping';
|
||||||
|
elif[ "$3" = "restart" ]; then STA='Restarting'
|
||||||
|
fi
|
||||||
|
echo -e "${idsCL[LightBlue]}${SER} ${STA}...${idsCL[Default]}"
|
||||||
|
ssh root@10.5.10.51 systemctl $3 $2
|
||||||
|
ssh root@10.5.10.52 systemctl $3 $2
|
||||||
|
ssh root@10.5.10.53 systemctl $3 $2
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
|
|
||||||
haproxy-start)
|
haproxy-start)
|
||||||
sleep 15
|
sleep 15
|
||||||
|
|||||||
Reference in New Issue
Block a user