update-1.2.sh 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. #!/bin/bash
  2. if [ "${EUID}" -ne 0 ]; then
  3. echo "You need to run this script as root"
  4. exit 1
  5. fi
  6. if [ "$(systemd-detect-virt)" == "openvz" ]; then
  7. echo "OpenVZ is not supported"
  8. exit 1
  9. fi
  10. red='\e[1;31m'
  11. green='\e[0;32m'
  12. NC='\e[0m'
  13. MYIP=$(wget -qO- ifconfig.co);
  14. # Validate Version Script
  15. versi=$(cat /home/ver)
  16. if [[ $versi == 1.2 ]]; then
  17. echo "Automatical Update In 3s"
  18. sleep 3
  19. else
  20. exit 0
  21. fi
  22. echo "Start Update"
  23. cd /usr/bin
  24. wget -O menu "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/menu.sh"
  25. wget -O add-host "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-host.sh"
  26. wget -O addd-ssh "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-ssh.sh"
  27. wget -O trial-ssh "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/trial-ssh.sh"
  28. wget -O change-port "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/change.sh"
  29. wget -O port-ovpn "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-ovpn.sh"
  30. wget -O port-ssl "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-ssl.sh"
  31. wget -O port-wg "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-wg.sh"
  32. wget -O port-tr "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-tr.sh"
  33. wget -O port-sstp "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-sstp.sh"
  34. wget -O port-squid "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-squid.sh"
  35. wget -O port-ws "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-ws.sh"
  36. wget -O port-vless "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/port-vless.sh"
  37. wget -O webmin "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/webmin.sh"
  38. wget -O xp "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/xp.sh"
  39. wget -O speed-limiter "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/speed-limiter.sh"
  40. wget -O add-sstp "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-sstp.sh"
  41. wget -O add-ws "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-ws.sh"
  42. wget -O add-vless "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-vless.sh"
  43. wget -O add-tr "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/add-tr.sh"
  44. wget -O update "https://raw.githubusercontent.com/EvoTeamMalaysia/AutoScript/main/update-1.2.sh"
  45. chmod +x change-port
  46. chmod +x add-host
  47. chmod +x port-ovpn
  48. chmod +x port-ssl
  49. chmod +x port-wg
  50. chmod +x port-sstp
  51. chmod +x port-tr
  52. chmod +x port-squid
  53. chmod +x port-ws
  54. chmod +x port-vless
  55. chmod +x webmin
  56. chmod +x xp
  57. chmod +x speed-limiter
  58. chmod +x update
  59. echo "0 5 * * * root clear-log && reboot" > /etc/crontab
  60. echo "0 0 * * * root xp" > /etc/crontab
  61. cd
  62. echo "1.3" > /home/ver
  63. clear
  64. echo " Fix minor Bugs"
  65. echo " Now You Can Change Port Of Some Services"
  66. echo " Reboot 3 Sec"
  67. sleep 3
  68. rm -f update.sh
  69. reboot