From 05cbe647bd52f7f7d438ce92a3349f07e232ba03 Mon Sep 17 00:00:00 2001 From: TRaSH Date: Sun, 15 Aug 2021 21:12:07 +0200 Subject: [PATCH] Updated: to new wireguard option without the use of the scripts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From Torguard Mail on July: TorGuard’s Stable Peers API Update for External Wireguard Clients: Good news - we have now updated our wireguard API to prevent the 24hr config expiration on third party clients - all new configs generated using our config generator from now on will now stay active for the time your account has an active subscription. --- ...w-to-setup-Torguard-for-port-forwarding.md | 58 ------------------- 1 file changed, 58 deletions(-) diff --git a/docs/Misc/How-to-setup-Torguard-for-port-forwarding.md b/docs/Misc/How-to-setup-Torguard-for-port-forwarding.md index 9421efec5..94ecd3fb1 100644 --- a/docs/Misc/How-to-setup-Torguard-for-port-forwarding.md +++ b/docs/Misc/How-to-setup-Torguard-for-port-forwarding.md @@ -195,64 +195,6 @@ Choose your preferred VPN Tunnel type. Rename the file from `*.conf` to `wg0.conf` and copy it to your wireguard folder of your VPN torrent client. - Before we can make use of it you will need to edit the `wg0.conf` file first and add the following at line 7. - - ```bash - PreUp = bash /config/wireguard/torguard.sh - ``` - - Your wg0.conf should look something like this: - - ```shell linenums="1" - # TorGuard WireGuard Config - [Interface] - PrivateKey = secretprivatekey - ListenPort = 51820 - DNS = 1.1.1.1 - Address = xx.xx.xxx.xx/24 - PreUp = bash /config/wireguard/torguard.sh - - [Peer] - PublicKey = publickey - AllowedIPs = 0.0.0.0/0 - Endpoint = xx.xxx.xx.xxx:1443 - PersistentKeepalive = 25 - ``` - - Then you will need to create a bash script in your `/config/wireguard` of your torrent client appdata folder named `torguard.sh` (*This script will get executed just before starting WireGuard*) with the following info it depending which images you're using. - - ##### Hotio's VPN Containers - - ??? example "Hotio's VPN Containers" - - ```bash - #!/usr/bin/bash - - pubkey=$(grep PrivateKey "${CONFIG_DIR}/wireguard/wg0.conf" | awk '{print $3}' | wg pubkey) - wgserver=$(grep Endpoint "${CONFIG_DIR}/wireguard/wg0.conf" | awk '{print $3}') - - curl -ksG -u "${TORGUARD_USER}":"${TORGUARD_PASS}" \ - --data-urlencode "public-key=${pubkey}" "https://${wgserver}/api/v1/setup" - ``` - - You will also have to add the additional environment variables `TORGUARD_USER` and `TORGUARD_PASS` or fill them in into the script directly (see curl command). These credentials are the ones we created [HERE](#create-a-user-account). - - ##### Binhex VPN Containers - - ??? example "Binhex VPN Containers" - - ```bash - #!/usr/bin/bash - - pubkey=$(grep PrivateKey "config/wireguard/wg0.conf" | awk '{print $3}' | wg pubkey) - wgserver=$(grep Endpoint "config/wireguard/wg0.conf" | awk '{print $3}') - - curl -ksG -u "${VPN_USER}":"${VPN_PASS}" \ - --data-urlencode "public-key=${pubkey}" "https://${wgserver}/api/v1/setup" - ``` - - You will also have to add the additional environment variables `VPN_USER` and `VPN_PASS or fill them in into the script directly (see curl command). These credentials are the ones we created [HERE](#create-a-user-account). - ------ THNX: