Skip to content

Respect rtorrent config file #1040

@rkdover

Description

@rkdover

Type: Bug Report

  • [ x ] Try to follow the update procedure described in the README and try again before opening this issue.

Your Environment

  • Version used:
    Docker (jesec/flood:latest, sha256:87259979d6ff581e463491475ccf22013775066e6c44c1051a88db8dd9644159)
  • Operating system and version:
    Debian GNU/Linux 12 (bookworm) x86_64
  • Torrent client and version:
    rtorrent/0.9.8/0.13.8

Summary

When starting flood, connected to a dockerized rtorrent, the default settings for flood are pushed onto rtorrent. E.g. DHT enabled, which port is open. With a setup that configures the listening port dynamically, this behavior in flood makes automation more difficult (and is arguably nonsensical).

Expected Behavior

Fetch current config from rtorrent and fill in the settings UI accordingly. Do not change torrent client settings without user request. If client settings have changed between flood sessions, respect those.

Current Behavior

Flood writes its own default settings to rtorrent on startup.

Possible Solution

Fetch client settings after connecting, save these to flood db.

Steps to Reproduce

docker-compose.yml:

services:
  flood:
    image: jesec/flood
    user: 1000:1000
    restart: always
    command: --auth=none --rtsocket /rtorrent/rtorrent.sock --host 0.0.0.0
    environment:
      HOME: /config
    volumes:
      - ./flood:/config/.local/share/flood
      - /data:/data
      - ./rtorrent:/rtorrent
  rtorrent:
    image: jesec/rtorrent:0.9.8-r16
    user: 1000:1000
    restart: always
    command: ["-o", "system.daemon.set=true"]
    environment:
      HOME: /config
    volumes:
      - ./rtorrent:/config/.local/share/rtorrent
      - /data:/data

example .rtorrent.rc:

## Import default configurations
import = /config/defaults_rtorrent.rc

# Tracker-less torrent and UDP tracker support
# (conservative settings for 'private' trackers, change for 'public')
dht.mode.set = disable
protocol.pex.set = no
trackers.use_udp.set = no

# Memory resource usage (increase if you have a large number of items loaded,
# and/or the available resources to spend)
pieces.memory.max.set = 4000M
network.xmlrpc.size_limit.set = 32M

network.port_range.set = 44646-44646

# Write a PID file into the session directory
execute.throw = sh, -c, (cat, "echo >", (session.path), "rtorrent.pid", " ", (system.pid))


Following this example, both network.port_range and dht.mode will be set to the flood defaults. ("dht":true, networkPortRange":"6881-6999")

Context

Docker compose stack (gluetun+rtorrent+flood) that handles VPN providers with dynamically forwarded ports.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions