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

[BUG] Container overwrites configs and doesn't respect directories #251

Closed
1 task done
proudhon opened this issue Jul 31, 2023 · 11 comments
Closed
1 task done

[BUG] Container overwrites configs and doesn't respect directories #251

proudhon opened this issue Jul 31, 2023 · 11 comments

Comments

@proudhon
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

Container overwrites configs and doesn't respect directories.
The first time i run the (rootless) container it will actually download the files in the /downloads/incomplete and /complete directories i specified but as soon as stop the container (docker compose down) and restart it (docker compose up) it will store complete and incomplete files in /downloads even if i specify the directory from the webui until i remove the /config folder and start over by setting folders via webui.

Also,

This section always gets overwritten when the container exits:

[Preferences]
Downloads\SavePath=/downloads/
Downloads\TempPath=/downloads/incomplete/

This section always stays the same:

[BitTorrent]
Session\DefaultSavePath=/complete
Session\ExcludedFileNames=
Session\Port=6881
Session\QueueingSystemEnabled=true
Session\TempPath=/downloads/incomplete/
Session\TempPathEnabled=true

Expected Behavior

The container respects directory configuration.

Steps To Reproduce

See current behavior & docker-compose.yml

Environment

- OS: Debian 12
- How docker service was installed: default docker.com rootless procedure

CPU architecture

x86-64

Docker creation

qbittorrent:
    image: lscr.io/linuxserver/qbittorrent
    container_name: qbittorrent
    network_mode: service:wireguard
    environment:
      - PUID=1001
      - PGID=1001
      - TZ=Europe/Rome
      - WEBUI_PORT=8086
    volumes:
      - /home/[REDACTED]/dlstack/qbittorrent/config:/config
      - /home/[REDACTED]/dlstack/cache/qbittorrent:/downloads/incomplete
      - /home/[REDACTED]/dlstack/downloads/qbittorrent:/complete
    restart: unless-stopped

Container logs

[migrations] started
[migrations] no migrations found
───────────────────────────────────────

      ██╗     ███████╗██╗ ██████╗ 
      ██║     ██╔════╝██║██╔═══██╗
      ██║     ███████╗██║██║   ██║
      ██║     ╚════██║██║██║   ██║
      ███████╗███████║██║╚██████╔╝
      ╚══════╝╚══════╝╚═╝ ╚═════╝ 

   Brought to you by linuxserver.io
───────────────────────────────────────

To support LSIO projects visit:
https://www.linuxserver.io/donate/

───────────────────────────────────────
GID/UID
───────────────────────────────────────

User UID:    1001
User GID:    1001
───────────────────────────────────────

[custom-init] No custom files found, skipping...
WebUI will be started shortly after internal preparations. Please wait...
Connection to localhost (127.0.0.1) 8086 port [tcp/*] succeeded!
[ls.io-init] done.
@github-actions
Copy link

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

@j0nnymoe
Copy link
Member

Can you try the same without using rootless please?

@proudhon
Copy link
Author

Without rootless the container overwrites both sections mentioned at each stop, but manually selecting the directory in web ui always downloads files in the correct paths.

@j0nnymoe
Copy link
Member

I would expect the file to get overwritten if you're editing it outside of the app and not saving it with the correct permissions/ownership.

As on start up, It checks to see if it can see a config file there https://github.com/linuxserver/docker-qbittorrent/blob/master/root/etc/s6-overlay/s6-rc.d/init-qbittorrent-config/run#L7

@proudhon
Copy link
Author

When running rootless it chowns to the highest SUBUID in the range for PUID 1001 (this is true for all files, configs and downloads) and therefore i can no longer edit them if not with sudo.
When running rootful all files are owned as username:group, keeping in mind that i didn't change the PUID and GUID envs, Should i set those to 0?

@j0nnymoe
Copy link
Member

I can't comment on rootless, are containers are not designed to run in that environment nor do we provide support for it.

You should not be setting these to 0 as that means qbittorrent will be running as root.

@thespad
Copy link
Member

thespad commented Jul 31, 2023

Running rootless shouldn't make any difference to how the container operates with regards to the config files unless you're mounting /config somewhere weird like an NFS mount.

@proudhon
Copy link
Author

proudhon commented Jul 31, 2023

Running rootless shouldn't make any difference to how the container operates with regards to the config files unless you're mounting /config somewhere weird like an NFS mount.

/config is on a regular directory and so is /downloads/incomplete

/complete is in a cifs mount.

I can confirm that running the container as non-rootless works with this configuration

Edit: But weirdly enough running it as rootless works too, the first time

@LinuxServer-CI
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. This might be due to missing feedback from OP. It will be closed if no further activity occurs. Thank you for your contributions.

@drizuid
Copy link
Member

drizuid commented Oct 11, 2023

As we do not support or design to support rootless, though it CAN work, our expectation is that users running an unsupported setup are able to support it themselves. Best-effort help is available on our discord in #other-support, but a github issue would be inappropriate for an unsupported configuration like this. Closing this as OP confirmed the supported setup works as expected.

@drizuid drizuid closed this as not planned Won't fix, can't repro, duplicate, stale Oct 11, 2023
@LinuxServer-CI LinuxServer-CI moved this from Issues to Done in Issue & PR Tracker Oct 11, 2023
Copy link

This issue is locked due to inactivity

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Archived in project
Development

No branches or pull requests

5 participants