linuxserver / docker-deluge

GNU General Public License v3.0
250 stars 89 forks source link

Unable to pull username from container #172

Closed instantdreams closed 1 year ago

instantdreams commented 2 years ago

Expected Behavior

The docker container to run under a named user that can be referenced for remote connections.

Current Behavior

Use host or container commands to determine the username:

$ whoami
serviceuser

$ id $username
uid=1000(serviceuser) gid=1000(serviceuser) groups=1000(serviceuser),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video),46(plugdev),108(netdev),998(docker)

$ docker inspect deluge | grep -i user
            "UsernsMode": "",
            "User": "",

$ docker exec -it deluge bash
root@f8a016850612:/# whoami
root

Steps to Reproduce

I am attempting to add the Deluge integration for Home Assistant. The integration required the following fields:

Whatever I try, I get "Failed to connect".

Environment

OS: Linux service 5.18.0-1-amd64 #1 SMP PREEMPT_DYNAMIC Debian 5.18.2-1 (2022-06-06) x86_64 GNU/Linux CPU architecture: arm64 How docker service was installed: Official Docker Repository

Command used to create docker container (run/create/compose/screenshot)

$ docker-compose --file /srv/deluge/docker-compose.yml config
services:
  deluge:
    container_name: deluge
    environment:
      DELUGE_LOGLEVEL: error
      PGID: '1000'
      PUID: '1000'
      TZ: America/Edmonton
    image: lscr.io/linuxserver/deluge:latest
    network_mode: container:nordlynx
    restart: unless-stopped
    volumes:
    - /srv/deluge/config:/config:rw
    - /media/Downloads:/downloads:rw
version: '2.1'

Docker logs

$ docker-compose --file /srv/deluge/docker-compose.yml logs
Attaching to deluge
deluge    | [custom-init] No custom services found, skipping...
deluge    | [migrations] started
deluge    | [migrations] no migrations found
deluge    |
deluge    | -------------------------------------
deluge    |           _         ()
deluge    |          | |  ___   _    __
deluge    |          | | / __| | |  /  \
deluge    |          | | \__ \ | | | () |
deluge    |          |_| |___/ |_|  \__/
deluge    |
deluge    |
deluge    | Brought to you by linuxserver.io
deluge    | -------------------------------------
deluge    |
deluge    | To support LSIO projects visit:
deluge    | https://www.linuxserver.io/donate/
deluge    | -------------------------------------
deluge    | GID/UID
deluge    | -------------------------------------
deluge    |
deluge    | User uid:    1000
deluge    | User gid:    1000
deluge    | -------------------------------------
deluge    |
deluge    | [custom-init] No custom files found, skipping...
deluge    | [ls.io-init] done.
github-actions[bot] commented 2 years ago

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

aptalca commented 2 years ago

username is abc

instantdreams commented 2 years ago

I tried username abc with password as either "deluge" or my web gui password. It still says "Failed to connect".

djevrek commented 2 years ago

I had exact same problem, and i tought that my password was wrong. I found a way to reset it by removing pdw line from web.conf, and that should revert password back to default "deluge" but that also doesnt work. So now, i cant even access web interface via browser, nor add deluge to home assistant.

instantdreams commented 1 year ago

The username for remote connections is defined in the Thin Client configuration guide. Make sure the appropriate Authentication level is set.

molarcandle commented 1 year ago

The username for remote connections is defined in the Thin Client configuration guide. Make sure the appropriate Authentication level is set.

I followed that guide and added 58846 to the forwarded ports in docker-compose.yml. I still get Connection was refused by other side:111:Connection refused when I try to connect from my thin client Deluge. The client and server version match already. What am I missing?

Edit: Duh. Have to actually recreate the container not just restart it.