From be8dffff413a223fad375a28e9167a6eaf002d50 Mon Sep 17 00:00:00 2001 From: Shadchamp Date: Tue, 24 Dec 2024 08:53:54 -0500 Subject: [PATCH] Create run.sh --- run.sh | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 run.sh diff --git a/run.sh b/run.sh new file mode 100644 index 0000000..dc5ce2a --- /dev/null +++ b/run.sh @@ -0,0 +1,42 @@ +#!/bin/bash + +# Stop and remove all existing gluetun and biglyBT containers +podman rm -f $(podman ps -aq --filter "ancestor=qmcgaw/gluetun") +podman rm -f $(podman ps -aq --filter "ancestor=fullaxx/biglybt") + +#Remove old Netowkr Interfaces +podman network prune -f + +# Loop through 5 times to create 5 gluetun containers and networks +for i in $(seq 1 5); do + # Create the network for this gluetun container + podman network create gluetun-network-$i + + podman run -d \ + --name gluetun-$i \ + --network gluetun-network-$i \ + --cap-add=NET_ADMIN \ + --device /dev/net/tun \ + -e VPN_SERVICE_PROVIDER=airvpn \ + -e VPN_TYPE=wireguard \ + -e WIREGUARD_PRIVATE_KEY=2340912349210421042 \ + -e WIREGUARD_PRESHARED_KEY=124231241234123412 \ + -e WIREGUARD_ADDRESSES=ADDRESSES_HERE \ + --security-opt label=disable \ + qmcgaw/gluetun +done + +# Create biglybt container connected to all gluetun networks +podman run -d \ + --name=biglybt \ + --network gluetun-network-1 \ + --network gluetun-network-2 \ + --network gluetun-network-3 \ + --network gluetun-network-4 \ + --network gluetun-network-5 \ + -v /biglybt/data:/root/.biglybt \ + -v /biglybt/in:/in \ + -v /biglybt/out:/out \ + --security-opt label=disable \ + -p 5901:5901 \ + fullaxx/biglybt