From 6c9b5b6005f0ad5ee482c69a38dc20c8373ab0bc Mon Sep 17 00:00:00 2001 From: Esteban Mackay Q Date: Sun, 1 Oct 2023 21:13:18 -0500 Subject: [PATCH] update --- install/dvswitch.sh | 15 +++++++++++++++ install/update-dash-dvs.sh | 18 +++++++++++++++++- 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/install/dvswitch.sh b/install/dvswitch.sh index 1e3ca89..5fbde54 100644 --- a/install/dvswitch.sh +++ b/install/dvswitch.sh @@ -131,11 +131,26 @@ sed -i "s/www\/html/www\/dvs/g" /usr/local/sbin/update-config.sh sed -i "s/www\/html/www\/dvs/g" /var/lib/dpkg/info/dvswitch* sed -i "s/Language=en_US/Language=es_ES/g" /opt/NXDNGateway/NXDNGateway.ini sed -i "s/Language=en_US/Language=es_ES/g" /opt/P25Gateway/P25Gateway.ini +sed -i "s/8080/9009/g" /var/www/dvs/include/*.* if [ ! -d "/var/www/dvs/qrz_photo" ] then sudo mkdir /var/www/dvs/qrz_photo fi sudo chmod o+w /var/www/dvs/qrz_photo +if grep -q "8080" /lib/systemd/system/webproxy.service; then + systemctl stop webproxy.service + sed -i "s/8080/9009/g" /opt/Web_Proxy/proxy.js + sed -i "s/8080/9009/g" /lib/systemd/system/webproxy.service + systemctl daemon-reload +fi +if ! sudo systemctl status webproxy.service |grep "service; enabled;" >/dev/null 2>&1 + then + sudo systemctl enable webproxy.service +fi +if ! systemctl status webproxy.service |grep "Active: active" >/dev/null 2>&1 + then sudo systemctl restart webproxy.service + +fi # sudo cat > /opt/MMDVM_Bridge/MMDVM_Bridge.ini <<- "EOF" [General] diff --git a/install/update-dash-dvs.sh b/install/update-dash-dvs.sh index 0391cb6..da91394 100644 --- a/install/update-dash-dvs.sh +++ b/install/update-dash-dvs.sh @@ -26,11 +26,27 @@ bash -c "$(curl -fsSL https://gitlab.com/hp3icc/emq-TE1/-/raw/main/menu/menu-dvs sed -i "s/www\/html/www\/dvs/g" /usr/local/sbin/update-config.sh sed -i "s/www\/html/www\/dvs/g" /var/lib/dpkg/info/dvswitch* # +sed -i "s/8080/9009/g" /var/www/dvs/include/*.* if [ ! -d "/var/www/dvs/qrz_photo" ] then sudo mkdir /var/www/dvs/qrz_photo fi -sudo chmod o+w /var/www/dvs/qrz_photo +sudo chmod o+w /var/www/dvs/qrz_photo +if grep -q "8080" /lib/systemd/system/webproxy.service; then + systemctl stop webproxy.service + sed -i "s/8080/9009/g" /opt/Web_Proxy/proxy.js + sed -i "s/8080/9009/g" /lib/systemd/system/webproxy.service + systemctl daemon-reload +fi +if ! sudo systemctl status webproxy.service |grep "service; enabled;" >/dev/null 2>&1 + then + sudo systemctl enable webproxy.service +fi +if ! systemctl status webproxy.service |grep "Active: active" >/dev/null 2>&1 + then sudo systemctl restart webproxy.service + +fi +# if [ ! -f "/lib/systemd/system/http.server-dvs.service" ] then sudo cat > /lib/systemd/system/http.server-dvs.service <<- "EOF"