This commit is contained in:
PancakeSparkle 2025-10-01 01:43:36 +02:00
parent c97a74c933
commit df962d5ea1

View File

@ -1,13 +1,13 @@
#!/bin/bash
path=/your/path/here/
opts=("Switch to router VPN" "Switch to Cloudflare VPN")
path=/root/globe/services/invidious
opts=("Switch to router VPN" "Switch to Cloudflare VPN" "Exit")
PS3="Choose an option:"
select o in "${opts[@]}"
do
case "$REPLY" in
1) echo "Switching to router VPN..."
rm $path/wg0.conf
ln -s wg0.conf.router wg0.conf
ln -s $path/wg0.conf.router $path/wg0.conf
docker compose -f $path/docker-compose.yml down >/dev/null 2>&1
docker compose -f $path/docker-compose.yml up -d >/dev/null 2>&1
exit 0
@ -15,10 +15,12 @@ do
2) echo "Switching to Cloudflare VPN..."
rm $path/wg0.conf
ln -s wg0.conf.cf wg0.conf
ln -s $path/wg0.conf.cf $path/wg0.conf
docker compose -f $path/docker-compose.yml down >/dev/null 2>&1
docker compose -f $path/docker-compose.yml up -d >/dev/null 2>&1
exit 0
;;
3) break;
;;
esac
done