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

Add torrenting port configuration support #288

Merged
merged 1 commit into from
Feb 14, 2024
Merged

Add torrenting port configuration support #288

merged 1 commit into from
Feb 14, 2024

Conversation

pcdevil
Copy link
Contributor

@pcdevil pcdevil commented Feb 10, 2024

linuxserver.io


  • I have read the contributing guideline and understand that I have made the correct modifications

Description:

Adds TORRENTING_PORT environment variable for easy qBittorrent port change.

Benefits of this PR and context:

The torrenting port is can override qBittorrent's setting without changing the configuration. This increases the portability of the container and adds more granular control over its behaviour.

How Has This Been Tested?

  1. I built the container using the command provided in the Contribution guide
  2. Then I set the image in an existing docker-compose.yml to point the newly created image:
       qbittorrent:
    -     image: lscr.io/linuxserver/qbittorrent:latest
    +     image: linuxserver/qbittorrent
         hostname: qbittorrent
         volumes:
           - /media/downloads:/downloads
         ports:
           - 6887:6887
           - 6887:6887/udp
         environment:
           TORRENTING_PORT: 6887
  3. Then (I waited a bit, and) I started the container and ran docker compose ps --format 'table {{.Service}}\t{{.Image}}\t{{.Status}}\t{{.Ports}}' for checking the status:
    $ docker compose  ps --format 'table {{.Service}}\t{{.Image}}\t{{.Status}}\t{{.Ports}}'
    SERVICE       IMAGE                     STATUS                   PORTS
    qbittorrent   linuxserver/qbittorrent   Up 9 minutes (healthy)   6881/tcp, 8080/tcp, 6881/udp, 0.0.0.0:6887->6887/tcp, 0.0.0.0:6887->6887/udp, :::6887->6887/tcp, :::6887->6887/udp
  4. Then I also logged in via docker compose exec qbittorrent sh and checked the running command:
    root@qbittorrent:/# ps aux | grep abc
    abc          216  2.8  0.0  73636 55696 ?        Ssl  11:16   0:05 /usr/bin/qbittorrent-nox --webui-port=8080 --torrenting-port=6887
    root         399  0.0  0.0   1612     4 pts/0    S+   11:19   0:00 grep abc
  5. Finally, I checked if the client's connection is active on a tracker.

Source / References:

Relates to the stale #227 pull request.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for opening this pull request! Be sure to follow the pull request template!

@LinuxServer-CI
Copy link
Contributor

I am a bot, here are the test results for this PR:
https://ci-tests.linuxserver.io/lspipepr/qbittorrent/4.6.3-r0-pkg-24d6d696-dev-f1b14b8d490202a869e466bdffc05f71d430c778-pr-288/index.html
https://ci-tests.linuxserver.io/lspipepr/qbittorrent/4.6.3-r0-pkg-24d6d696-dev-f1b14b8d490202a869e466bdffc05f71d430c778-pr-288/shellcheck-result.xml

Tag Passed
amd64-4.6.3-r0-pkg-24d6d696-dev-f1b14b8d490202a869e466bdffc05f71d430c778-pr-288
arm64v8-4.6.3-r0-pkg-24d6d696-dev-f1b14b8d490202a869e466bdffc05f71d430c778-pr-288

@thespad
Copy link
Member

thespad commented Feb 10, 2024

I don't have an issue with this in principle but please remove the readme references to running without a /config mount as it's something we will not support and don't want users attempting without understanding the implications (like not persisting their torrents on an upgrade, for a start).

Will also need a matching PR for the libtorrentv1 branch.

@pcdevil
Copy link
Contributor Author

pcdevil commented Feb 10, 2024

Hey @thespad,
Thank you for looking at my pull request!

I don't have an issue with this in principle but please remove the readme references to running without a /config mount as it's something we will not support and don't want users attempting without understanding the implications (like not persisting their torrents on an upgrade, for a start).

Would you like me to re-word the description in readme-vars.yml too, or just the pull request description?

Will also need a matching PR for the libtorrentv1 branch.

Thanks for the reminder, I'll create it shortly!

@thespad
Copy link
Member

thespad commented Feb 10, 2024

readme-vars please.

@pcdevil
Copy link
Contributor Author

pcdevil commented Feb 10, 2024

Updated both readme-vars.yml and pull request description, see the amended e0e573c commit.

Let me know what do you think!

@LinuxServer-CI
Copy link
Contributor

I am a bot, here are the test results for this PR:
https://ci-tests.linuxserver.io/lspipepr/qbittorrent/4.6.3-r0-pkg-24d6d696-dev-e0e573c2480df19708ec2ba160bda5703f4c7d15-pr-288/index.html
https://ci-tests.linuxserver.io/lspipepr/qbittorrent/4.6.3-r0-pkg-24d6d696-dev-e0e573c2480df19708ec2ba160bda5703f4c7d15-pr-288/shellcheck-result.xml

Tag Passed
amd64-4.6.3-r0-pkg-24d6d696-dev-e0e573c2480df19708ec2ba160bda5703f4c7d15-pr-288
arm64v8-4.6.3-r0-pkg-24d6d696-dev-e0e573c2480df19708ec2ba160bda5703f4c7d15-pr-288

@thespad thespad merged commit 873a9fa into linuxserver:master Feb 14, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants