binhex / arch-rtorrentvpn

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

IMPORTANT - Existing Users 22nd Oct 2019 - IMPORTANT #124

Closed binhex closed 4 years ago

binhex commented 4 years ago

Historically it has been difficult/impossible to change the listening port for rtorrent programmatically whilst its running, this lead to the only option which is to sigint rtorrent and change the port and then restart the process, this unfortunately can lead to situations where the process does not end nicely and thus rtorrent cannot be restarted.

Wind forward in time and this is now possible, however in order to do this we need to supply the credentials the authenticate with rtorrent before we can issues commands. As i don't know what each user has set their rpc2 and web ui passwords to (and i obviously shouldn't know this either!) then the only way for me to do this going forward is to allow the user to define the credentials for rpc2 and web ui as environment variables.

So from the next build if you have changed the username and password from the defaults (user admin, password rutorrent) then you will need to add in the following 'variables' :-

Key                 Value               Default         Description
RPC2_USER           <your username>     admin           sets the username for RPC2 auth
RPC2_PASS           <your passs>        rutorrent       sets the password for RPC2 auth
ENABLE_WEBUI_AUTH   yes/no              yes             sets web ui authentication for web ui (nginx) - if you are reverse proxying you probably want this set to no, otherwise yes.
WEBUI_USER          <your username>     admin           sets the username for web ui auth
WEBUI_PASS          <your passs>        rutorrent       sets the password for web ui auth

The above will result in a more stable rtorrent/rutorrent experience, whilst allowing us to maintain a working incoming port during all situations, i hope you agree a worthy improvement! (testing was a bitch).

enoch85 commented 4 years ago

I have several users accessing the same UI, do I need to add those users in as -e variables?

Also, does this mean that the createuser script isn't working anymore?

binhex commented 4 years ago

I have several users accessing the same UI, do I need to add those users in as -e variables?

no, you can't do that, the env vars for USER and PASS are purely for a single user account.

Also, does this mean that the createuser script isn't working anymore?

TBH i haven't really focused on the createuser.sh script during this work, ive had a look at it and it did need modifications which ive now delivered, please pull down the new image.

So in answer to your question, yes the script is still required IF you need to create any additional account(s).

note the additional parameter to allow you to specify the password:-

docker exec -it <container name> /home/nobody/createuser.sh <username to create> **<password for the user>**
enoch85 commented 4 years ago

Thanks.

IMHO you should fix so that the old users are migrated.

enoch85 commented 4 years ago

Not needed for me though as I deleted the old authfile and created the users manually with new passwords, but just if you have time. If you decide to do it, please check if the old auth file is still there so that you don't overwrite for users like me :)

binhex commented 4 years ago

This information is now out of date due to the enablement of randomised passwords (if not defined) for the web ui and rpc2 - closing this issue and un-pinning.