This commit is contained in:
Your Name 2023-04-28 08:43:05 -06:00
parent cf2075f17f
commit 53dae5fc69
7 changed files with 2567 additions and 0 deletions

21
Dockerfile Normal file
View File

@ -0,0 +1,21 @@
FROM docker.io/debian:testing
RUN export TERM=xterm
RUN apt update;apt install -y bash curl git python3 build-essential screen rtorrent unzip wget wireguard wireguard-tools iproute2 procps
COPY nodesource /etc/apt/preferences.d/
RUN curl -sL https://deb.nodesource.com/setup_16.x | bash -;apt update; apt -y install nodejs
RUN mkdir /srv/torrent;mkdir /srv/torrent/downloads;mkdir /srv/torrent/.session
WORKDIR /srv/torrent
RUN wget https://github.com/jesec/flood/archive/refs/tags/v4.7.0.zip;unzip v4.7.0.zip;mv flood-4.7.0 flood
WORKDIR /srv/torrent/flood
RUN sed -i 's/127.0.0.1/0.0.0.0/g' /srv/torrent/flood/config.ts
RUN npm install
RUN npx browserslist@latest --update-db
RUN npm run build
COPY .rtorrent.rc /opt/
ADD start.sh /
COPY wg0.conf /etc/wireguard/
CMD bash /start.sh

View File

@ -0,0 +1,22 @@
## rTorrent via Tor with the Flood UI
A simply way to download Torrent Files over Tor
### Software Used
* rTorrent
* Flood rTorrent UI
* Privoxy
* Tor
### Starting the Container
```
docker-compose up -d
```
### Accessing the UI
Open your browser to ```http://0.0.0.0:3000```
### Configuring Flood
When you first login Flood, it will ask you to enter a ```username``` and ```password```. Then it will ask you how to connect to rTorrent. For ```rTorrent Host```, enter ```127.0.0.1```. Enter ```5000``` for ```rTorrent Port``` and click ```Create Account```.

2466
config Normal file

File diff suppressed because it is too large Load Diff

16
docker-compose.yaml Normal file
View File

@ -0,0 +1,16 @@
version: '3'
services:
rtorrent:
build: .
restart: "always"
volumes:
- .:/root/Downloads
ports:
- "3000:3000"
networks:
- rtorrent
networks:
rtorrent:

3
nodesource Normal file
View File

@ -0,0 +1,3 @@
Package: *
Pin: origin deb.nodesource.com
Pin-Priority: 600

38
start.sh Normal file
View File

@ -0,0 +1,38 @@
#!/bin/bash
torrent-check(){
TORRENT_CHECK=$(ss -tlnp | grep -i rtorrent)
if [ ! -z "$TORRENT_CHECK" ]; then
echo "rTorrent is running!"
else
echo "rTorrent is not in Running!"
rm -f /root/rtorrent.lock
rm -f /root/Downloads/rtorrent.lock
/usr/bin/rtorrent &
fi
}
vpncheck(){
VPN_CHECK=$(ip a | grep -i wg0)
if [ ! -z "$VPN_CHECK" ]; then
echo "VPN is running!"
sleep 20
torrent-check
vpncheck
else
echo "VPN is not in Running!"
killall "/usr/bin/rtorrent"
killall openvpn
wg-quick up wg0
sleep 20
vpncheck
fi
}
apt update;apt install resolvconf -y
cp -f /opt/.rtorrent.rc /root/
npm start &
vpncheck
tail -f /dev/null

1
wg0.conf Normal file
View File

@ -0,0 +1 @@
replace this file with your VPN's file