Webserver integration.
By default deluge uses it's builtin webserver, but it's possible to use another webserver.
This setup depends on apache2 and mod_wsgi.
It serves the webui on the /deluge directory on your webserver.
Other wsgi-capable webservers should be able to run deluge too.
deluge_apache_config.py
Code: Select all
#!/usr/bin/env python
#config ; EDIT THIS
CONFIG_DIR = '/home/martijn/.config/deluge' #No trailing slashes.
BASE_URL = '/deluge' #the apache url /No trailing slashes.
#/config
#Do not edit this:
from deluge.ui.webui import apache
application = apache.get_wsgi_application(BASE_URL, CONFIG_DIR)
/etc/apache2/apache2.conf
Code: Select all
### deluge
# WSGIRestrictStdout must be Off , this will be fixed, eventually...
# deluge only supports 1 process, but you are free to configure the number of threads.
# more info:
# http://code.google.com/p/modwsgi/wiki/ConfigurationDirectives
WSGIRestrictStdout Off
WSGIProcessGroup deluge
WSGIDaemonProcess deluge processes=1 threads=25
Alias /deluge/static/ /usr/lib/python2.5/site-packages/deluge-0.6.0.0-py2.5-linux-i686.egg/deluge/ui/webui/static/
WSGIScriptAliasMatch ^/deluge/(.*) /home/martijn/prj/WebUi/scripts/deluge_apache_config.py/$1
Note: make sure that the config-dir is writable by the webserver-process (configuring the wsgi daemon user is left as an exersize to the reader)
tail /var/log/apache2/error.log when you're encountering problems.