binhex / arch-rtorrentvpn

Docker build script for Arch Linux base with ruTorrent, rTorrent, autodl-irssi, Privoxy and OpenVPN
GNU General Public License v3.0
238 stars 35 forks source link

script not being called rtorrent/deluged - docker permission issue? #68

Closed chienb closed 5 years ago

chienb commented 6 years ago

The torrent client is not calling my scripts, I've tested both your rtorrent and deluge dockers. All the other features are working properly and rt-postprocess.sh/test.sh works when calling from terminal and has the proper permissions(?).

chienb@seedbox:~/plex$ ls -la
total 72
drwxrwxr-x  2 chienb chienb  4096 Aug 20 11:20 .
drwxr-xr-x 23 chienb chienb  4096 Aug 20 14:35 ..
-rw-rw-r--  1 chienb chienb 48723 Aug 19 03:16 amc.log
-rw-rw-r--  1 chienb chienb  3091 Aug 19 02:53 amc.txt
-rwxrwxrwx  1 chienb chienb   755 Aug 20 11:20 rt-postprocess.sh
-rwxrwxrwx  1 chienb chienb    60 Aug 20 11:14 test.sh

Here is my system: https://pastebin.com/jtMz1BQ8 rtorrent- 0.9.7/0.13.7 ruTorremt- v3.8

I also made sure my admin user is part of the docker group

chienb@seedbox:~/plex$ id
uid=1000(chienb) gid=1000(chienb) groups=1000(chienb),4(adm),24(cdrom),27(sudo),30(dip),46(plugdev),114(lpadmin),115(sambashare),129(docker)
chienb@seedbox:~/plex$ getent group docker
docker:x:129:chienb

The docker command I'm using:

docker run --restart always \
    --cap-add=NET_ADMIN \
    -p 9080:9080 \
    -p 9443:9443 \
    -p 8118:8118 \
    -p 3000:3000 \
    --name=rtorrentvpn \
    -v /home/chienb/docker/rtorrentvpn/config:/config \
    -v /etc/localtime:/etc/localtime:ro \
    -v /media/chienb/plex:/media/chienb/plex \
    -e VPN_ENABLED=yes \
    -e VPN_USER=xxx \
    -e VPN_PASS=xxx \
    -e VPN_PROV=pia \
    -e STRICT_PORT_FORWARD=yes \
    -e ENABLE_PRIVOXY=no \
    -e ENABLE_FLOOD=no \
    -e ENABLE_AUTODL_IRSSI=no \
    -e LAN_NETWORK=192.168.1.89/24 \
    -e NAME_SERVERS=209.222.18.222,37.235.1.174,1.1.1.1,8.8.8.8,209.222.18.218,37.235.1.177,1.0.0.1,8.8.4.4 \
    -e DEBUG=true \
    -e PHP_TZ=America/Los_Angeles \
    -e UMASK=002 \
    -e PUID=1000 \
    -e PGID=129 \ (tried 1000 too)
    binhex/arch-rtorrentvpn

rtorrent.rc: https://pastebin.com/2mmAFcu3

ruTorrent webui breaks when I add log.add_output = “info”, "/home/chienb/plex/rtorrent.log" in the config file.

On the deluge side, I'm using the execute plugin. Added a test script to print log when a torrent is added, not working as well. deluge.log and webgui does show torrent was added.

#!/bin/bash
torrentid=$1
torrentname=$2
torrentpath=$3
echo "Torrent Details: " "$torrentname" "$torrentpath" "$torrentid"  >> /tmp/execute_script.log
fryfrog commented 6 years ago

You'd need to make sure the home directory was writable, but if you want logging why not put it w/ the other logging in /config?

If you put the script(s) there too, that'd be fine.