Feature #2313
closed[PATCH] X-sendfile support for mod_cgi
Description
Attached a patch to add x-sendfile support to mod_cgi.
Works the same as with Fastcgi.
Files
Updated by Max_nl over 13 years ago
- File cgi_x-send-file.patch cgi_x-send-file.patch added
Same patch but in unified format (forgot the -u option).
Updated by stbuehler over 13 years ago
- Target version changed from 1.4.29 to 1.4.x
Hm. I don't think it is worth it to add more complexity to mod_cgi (especially as the more powerful variant of x-sendfile is missing).
I recommend using fcgi-cgi instead; it comes with the bonus that you can run the scripts with a different user easily.
That way, your cgi apps would look like FastCGI to lighty.
Updated by Max_nl over 13 years ago
stbuehler wrote:
I recommend using fcgi-cgi instead; it comes with the bonus that you can run the scripts with a different user easily.
That way, your cgi apps would look like FastCGI to lighty.
It's for an embedded application where memory use is an issue.
Having to install spawn-fci, fcgi-cgi and libev just to be able to serve files, isn't going to help with that.
mod_cgi without x-sendfile is pretty worthless. Serve a file through a script that is larger than the device memory and it crashes due to lighttpd's tendency to buffer script output indefinitely.
Updated by stbuehler over 13 years ago
spawn-fcgi is not a memory issue (it is only a spawn helper and doesn't keep running), and mod_cgi needs memory too. i doubt there will be a big difference.
if you prefer using your patch that is fine ofc, but i don't want to maintain another copy of x-sendfile.
Updated by gstrauss over 8 years ago
- Status changed from Wontfix to Patch Pending
- Target version set to 1.4.40
Updated by gstrauss over 8 years ago
- Status changed from Patch Pending to Fixed
- % Done changed from 0 to 100
Applied in changeset 1f23ba9adf1d89d7d776312805c894a41b3f9296.
Also available in: Atom