Dan Donoghue
Since the deluge
and deluge-web
packages are omitted from the CentOS/RHEL and EPEL repositories for EL7, and I wouldn’t trust some unmaintained 3rd-party repo, I decided to build them from source. The instructions on the Deluge website fail to mention anything about what’s needed for CentOS/RHEL distributions so I guess I’ll write up what’s needed here.
Get the latest version of the source from the Deluge project’s Source Mirror. Then extract the source with tar -xf
.
The dependencies for Deluge and Deluge-Web are stated on the project’s website, although only the packages for Debian/Ubuntu are listed. Some of the dependencies are in the EPEL repo, so you’ll have to run this command first if you haven’t already enabled EPEL.
$ sudo yum install epel-release
Once the EPEL repo is enabled, run the following command to install the relevant dependencies.
$ sudo yum install python python-twisted-core python-twisted-web pyOpenSSL \
python-setuptools gettext intltool pyxdg python-chardet python-GeoIP \
rb_libtorrent-python2 python-setproctitle python-pillow python-mako
Change into the directory where you extracted the deluge source files, and run the following to build Deluge and Deluge-Web, and then install the application into the usuall locations.
$ python setup.py build
$ sudo python setup.py install
You shouldn’t be running a service under a standard user account, so create a user for deluge to run as.
$ sudo useradd -d /var/lib/deluge -c "deluge daemon account" -r -s /sbin/nologin -m deluge
These are the .service files taken from the Fedora version of Deluge. Create the deluge-daemon.service
and deluge-web.service
files inside /etc/systemd/system
. Once created, you can start and enable both services using the following commands.
$ systemctl daemon-reload
$ systemctl enable deluge-daemon-service
$ systemctl enable deluge-web.service
$ systemctl start deluge-daemon.service
$ systemctl start deluge-web.service
[Unit]
Description=Deluge Bittorrent Client Daemon
After=network.target
[Service]
User=deluge
ExecStart=/usr/bin/deluged -d
[Install]
WantedBy=multi-user.target
[Unit]
Description=Deluge Bittorrent Client Web Interface
After=network.target
[Service]
User=deluge
ExecStart=/usr/bin/deluge --ui web
[Install]
WantedBy=multi-user.target