Changes between Version 6 and Version 7 of UserGuide/WebUI/ReverseProxy


Ignore:
Timestamp:
03/30/2018 09:59:09 PM (6 years ago)
Author:
moonman
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • UserGuide/WebUI/ReverseProxy

    v6 v7  
    4040 ''Note: Ensure the trailing slashes are maintained.'' 
    4141 
     42 lighttpd Config: :: 
     43You will need to install `lua` >= 5.1 and make sure lighttpd is compiled with lua support. Lua will perform URL rewriting since lighty doesn't support it natively. 
     44{{{ 
     45server.modules += ( "mod_proxy" ) 
     46server.modules += ( "mod_magnet" ) 
     47server.modules += ( "mod_setenv" ) 
     48$HTTP["url"] =~ "^/deluge/" { 
     49    setenv.add-request-header = ( "X-Deluge-Base" => "/deluge/" ) 
     50    magnet.attract-raw-url-to = ( "/etc/lighttpd/lua/deluge.lua" ) 
     51    proxy.server = ( "" => ( "deluge" => ( "host" => "127.0.0.1", "port" => 8112 ) ) ) 
     52}}} 
     53 
     54`/etc/lighttpd/lua/deluge.lua` 
     55{{{ 
     56lighty.env["request.uri"] = string.sub(lighty.env["request.uri"], string.len('/deluge/')) 
     57return 
     58}}} 
     59 
    4260 WebUI `base` Option: :: 
    4361