Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DietPi-Software | rTorrent: ruTorrent web UI cannot connect to rTorrent daemon #2629

Closed
MichaIng opened this issue Mar 10, 2019 · 2 comments
Closed

Comments

@MichaIng
Copy link
Owner

Ref: https://dietpi.com/phpbb/viewtopic.php?f=11&t=5656
Verified on VM:

[10.03.2019 18:59:09] WebUI started.
[10.03.2019 18:59:09] No connection to rTorrent. Check if it is really running. Check $scgi_port and $scgi_host settings in config.php and scgi_port in rTorrent configuration file.
@MichaIng
Copy link
Owner Author

Identified the issue:

  • /root/.rtorrent.rc is not used as config file anymore by the systemd unit. There must have been something changed in systemd about which default HOME dir is used when executing as root.
  • Adding -o scgi_port=127.0.0.1:5000 to the command directly works, however we have a bunch of settings we want to set, so require a config file.
  • Overriding the HOME dir via systemd unit for sure works as well. We currently set WorkingDirectory=%h which obviously means user home. WorkingDirectory="~" is the current docs about that but does not work as well. Environment=HOME=/root or such would work.
  • However we should take this as chance to switch rTorrent to use it's own user as well.
  • Quick test with useradd -rm -s $(which nologin) -G dietpi -d /mnt/dietpi_userdata/rtorrent rtorrent works well. Then move .rtorrent.rc inside and no WorkingDirectory directive is required at all.
  • This aligns rTorrent to with the other torrent downloaders which as well run as their own user instead of root.

@MichaIng
Copy link
Owner Author

Fixed with: 16d37ea

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant