mod_fastcgi(4gx)
π mod_fastcgi(4gx) π
okay so this page is mod_fastcgi(4gx), direct from the Gromox admin references, and itβs literally about making FastCGI servers go brrr behind http(8gx). π¦
π Name π
mod_fastcgiβhttp(8gx)handler for proxying requests to FastCGI servers.
πΈ Description πΈ
mod_fastcgi can forward HTTP requests to one or more FastCGI servers when certain URIs are requested. Take special note of the file suffix column documented below; in particular, to override an entire directory, you may also need to edit the table for mod_cache(4gx). Donβt skip that part, bestie β itβs giving βimportant detail.β
β¨ Configuration directives β¨
This component shares http.cfg. See http(8gx).
πΊοΈ URI map πΊοΈ
The filemap that specifies which URIs to handle is fastcgi.txt, which is searched for in config_file_path. The usual location is /etc/gromox/fastcgi.txt.
Each line in this file consists of 7 columns separated by whitespace:
- Domain or asterisk-based wildcard (
"*","*.example.com") to match the HTTPHost:request header with. - URI path (prefix) to match.
- Mapped path that will be passed to the FastCGI executor. Note that the FastCGI process may additionally have a document root setting that could map the path one more time.
- File suffix (without dot) to match on, e.g.
php. - A file to use as the default file for a directory (similar to Apache httpd's
DirectoryIndex). - A set of headers, separated by the pipe symbol
|, which should be forwarded to the CGI handler. In absence of any desired extra headers, a single pipe can be used to fill the column. - Socket path: an
AF_LOCALsocket path to make the FastCGI request to.
If the file has no lines, no documents will be served this way. If the file is absent however, a set of default entries will be used.
π¦ Default entries π¦
* /sync /usr/share/grommunio-sync php index.php | /run/php-fpm/php-grommunio-sync-fpm.sock
* /web /usr/share/grommunio-web php index.php | /run/php-fpm/php-grommunio-web-fpm.sock
* /dav /usr/share/grommunio-dav php index.php | /run/php-fpm/php-grommunio-dav-fpm.sock
NOTE: The path designated for FPM sockets varies between distributions, and because some distributions also have security policies that involve path matching (e.g. via AppArmor), we are unable to choose a path that works out-of-the-box on all distro-provided platform configurations without fail. /run/php-fpm is used as the default in line with the Grommunio Appliance. Thatβs the whole tea β β distro paths are not one-size-fits-all.
π Files π
config_file_path/fastcgi.txtβ Map specifying with pathsmod_fastcgishould react to, and which FastCGI backend to route requests to.
π See also π
Mwah π β source/version: Gromox, page mod_fastcgi(4gx). Date: the footer didnβt give one, so weβre not inventing one, bestie. π«Ά
π¦ where this page comes from
- alpine 3.24: grommunio-gromox-doc 3.6-r0 Β· AGPL-3.0-or-later
- π the page's license: CC-BY-SA-4.0 or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms