mirror of https://gitlab.com/hp3icc/emq-TE1.git
Update menu-fdmr
This commit is contained in:
parent
e683790dfe
commit
9d0e60d5a2
|
|
@ -38,6 +38,14 @@ sudo nano /opt/FDMR-Monitor/fdmr-mon.cfg ;;
|
|||
sudo nano /opt/FDMR-Monitor2/fdmr-mon.cfg ;;
|
||||
5)
|
||||
sudo nano /opt/wdp &&
|
||||
if sudo systemctl status http.server-fdmr.service |grep active >/dev/null 2>&1
|
||||
then
|
||||
sudo systemctl stop http.server-fdmr.service
|
||||
fi &&
|
||||
if sudo systemctl status http.server-fdmr2.service |grep active >/dev/null 2>&1
|
||||
then
|
||||
sudo systemctl stop http.server-fdmr2.service
|
||||
fi &&
|
||||
variable1=$(grep "Web-Dashboar-Port:" /opt/wdp | grep -Eo '[A.0-9]{1,9}') &&
|
||||
if [ -z "$variable1" ]
|
||||
then variable1=80
|
||||
|
|
@ -46,14 +54,6 @@ fi &&
|
|||
sudo sed -i "s/ExecStart=.*/ExecStart=php -S 0.0.0.0:$variable1 -t \/var\/www\/fdmr\//g" /lib/systemd/system/http.server-fdmr.service &&
|
||||
sudo sed -i "s/ExecStart=.*/ExecStart=php -S 0.0.0.0:$variable1 -t \/var\/www\/fdmr2\//g" /lib/systemd/system/http.server-fdmr2.service &&
|
||||
systemctl daemon-reload &&
|
||||
if sudo systemctl status http.server-fdmr.service |grep active >/dev/null 2>&1
|
||||
then
|
||||
sudo systemctl stop http.server-fdmr.service
|
||||
fi
|
||||
if sudo systemctl status http.server-fdmr2.service |grep active >/dev/null 2>&1
|
||||
then
|
||||
sudo systemctl stop http.server-fdmr2.service
|
||||
fi
|
||||
if sudo systemctl status http.server-fdmr.service |grep "service; enabled;" >/dev/null 2>&1
|
||||
then
|
||||
sudo systemctl start http.server-fdmr.service
|
||||
|
|
@ -301,4 +301,4 @@ exit 0
|
|||
|
||||
EOF
|
||||
################
|
||||
sudo chmod +x /bin/menu*
|
||||
sudo chmod +x /bin/menu*
|
||||
|
|
|
|||
Loading…
Reference in New Issue