Quite simple!
Navigate to Accounts → Groups and add the following groups.
GID | 850 |
Name | qbittorrent |
Samba Authentication | unchecked |
Navigate to Accounts → Users and add the following users.
Full Name | qBittorrent |
Username | qbittorrent |
User ID | 850 |
New Primary Group | unchecked |
Primary Group | qbittorrent |
Primary Group | qbittorrent |
Disable Password | Yes |
Shell | nologin |
Samba Authentication | unchecked |
Navigate to Storage → Pools and add the datasets and permissions. We’ll use default 755
permissions for all datasets.
Path | /mnt/vault0/apps/qbittorrent |
User | qbittorrent |
Apply User | checked |
Group | qbittorrent |
Apply Group | checked |
Path | /mnt/vault0/media/torrents |
User | qbittorrent |
Apply User | checked |
Group | qbittorrent |
Apply Group | checked |
Connect to TrueNAS via SSH or similar.
# Create jail
iocage create --name qbittorrent --release 12.2-RELEASE dhcp=1 boot=1
# Mount jail config dataset
iocage exec qbittorrent mkdir /mnt/config
iocage fstab --add qbittorrent /mnt/vault0/apps/qbittorrent /mnt/config nullfs rw 0 0
# Mount media dataset
iocage exec qbittorrent mkdir /mnt/torrents
iocage fstab --add qbittorrent /mnt/vault0/media/torrents /mnt/torrents nullfs rw 0 0
# Update packages
iocage exec qbittorrent "pkg update && pkg upgrade"
# Install qBittorrent without GUI
iocage exec qbittorrent pkg install qbittorrent-nox
# Enable qBittorrent service
iocage exec qbittorrent sysrc qbittorrent_enable=YES
# Configure config directory
iocage exec qbittorrent sysrc qbittorrent_conf_dir=/mnt/config
# Start the service
iocage exec qbittorrent service qbittorrent start
Navigate to http://DHCP:8080
in your browser and login with the default credentials.
Username | Password |
---|---|
admin | adminadmin |
Navigate to qBittorrent menu and then Tools → Options… and change the Default Save Path to /mnt/torrents
:
There we go!
From there, you’ll just have to create a SMB share using the created folder.
I just got the interesting part from here.