diff --git a/scripts/giteainstall.sh b/scripts/giteainstall.sh index 7a7ba04..756b84e 100644 --- a/scripts/giteainstall.sh +++ b/scripts/giteainstall.sh @@ -22,8 +22,9 @@ sudo chmod -Rv 770 /etc/gitea sudo wget -O /etc/systemd/system/gitea.service https://git.oldgate.org/Sophia/thelinuxlist/raw/branch/main/systemd/gitea.service sudo systemctl enable --now gitea sudo systemctl start gitea + echo -e "==================================================================" -publicipaddress=$(curl -sS --connect-timeout 10 -m 60 https://ipv4.icanhazip.com/) +publicipaddress=$(curl -sS --connect-timeout 10 -m 60 https://ipv4.icanhazip.com/ || curl -sS --connect-timeout 10 -m 60 https://api.ipify.org ) intenalip=$(ip addr | grep -E -o '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}' | grep -E -v "^127\.|^255\.|^0\." | head -n 1) echo "Gitea Should be available at http://${intenalip}:3000" echo "Or If you are using a VPS at http://${publicipaddress}:3000"