mirror of
https://github.com/itdoginfo/podkop.git
synced 2025-12-11 05:56:55 +03:00
refactor: move add tunnel to function
This commit is contained in:
22
install.sh
22
install.sh
@@ -25,15 +25,16 @@ else
|
|||||||
[ -f /etc/config/dhcp-opkg ] && cp /etc/config/dhcp /etc/config/dhcp-old && mv /etc/config/dhcp-opkg /etc/config/dhcp
|
[ -f /etc/config/dhcp-opkg ] && cp /etc/config/dhcp /etc/config/dhcp-old && mv /etc/config/dhcp-opkg /etc/config/dhcp
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "What type of VPN or proxy will be used?"
|
add_tunnel() {
|
||||||
echo "1) VLESS, Shadowsocks (A sing-box will be installed)"
|
echo "What type of VPN or proxy will be used?"
|
||||||
echo "2) Wireguard"
|
echo "1) VLESS, Shadowsocks (A sing-box will be installed)"
|
||||||
echo "3) AmneziaWG"
|
echo "2) Wireguard"
|
||||||
echo "4) OpenVPN"
|
echo "3) AmneziaWG"
|
||||||
echo "5) OpenConnect"
|
echo "4) OpenVPN"
|
||||||
echo "6) Skip this step"
|
echo "5) OpenConnect"
|
||||||
|
echo "6) Skip this step"
|
||||||
|
|
||||||
while true; do
|
while true; do
|
||||||
read -r -p '' TUNNEL
|
read -r -p '' TUNNEL
|
||||||
case $TUNNEL in
|
case $TUNNEL in
|
||||||
|
|
||||||
@@ -92,7 +93,10 @@ while true; do
|
|||||||
echo "Choose from the following options"
|
echo "Choose from the following options"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
add_tunnel
|
||||||
|
|
||||||
echo "Installed podkop..."
|
echo "Installed podkop..."
|
||||||
opkg install $DOWNLOAD_DIR/podkop*.ipk
|
opkg install $DOWNLOAD_DIR/podkop*.ipk
|
||||||
|
|||||||
Reference in New Issue
Block a user