htpasswd -c /var/lib/deluged/apache2_password USERNAME
vim /etc/apache2/sites-enabled/SITECONF:
Redirect /deluge https://FQDN/deluge
vim /etc/apache2/sites-enabled/SSL_SITECONF:
<IfModule mod_proxy.c>
<Location /deluge>
AuthType Basic
AuthName "Login required"
AuthUserFile "/var/lib/deluged/apache2_password"
Require user USERNAME
ProxyPass http://127.0.0.1:8112/
ProxyPassReverse http://127.0.0.1:8112/
ProxyPassReverseCookieDomain 127.0.0.1 %{HTTP:Host}
ProxyPassReverseCookiePath / /deluge/
RequestHeader append X-Deluge-Base "/deluge/"
Order allow,deny
Allow from all
</Location>
</IfModule>
vim /etc/init/deluged-web.conf:
start on started deluged
stop on stopping deluged
expect daemon
env uid=UID
env gid=GID
env umask=027
exec start-stop-daemon -S -c $uid:$gid -k $umask -x /usr/bin/deluge-web -b /deluge
Leave a Reply