6 callcgi - CGI request handler for ashd(7)
10 *callcgi* [*-c*] [*-p* 'PROGRAM'] 'METHOD' 'URL' 'REST'
15 *callcgi* serves CGI scripts by translating the *ashd*(7) request
16 environment into a standard CGI environment and executing the target
17 file. It needs to be called with the `X-Ash-File` header added to the
18 request, as *dirplex*(1) does.
20 *callcgi* is a transient handler, as defined in *ashd*(7), and the
21 'METHOD', 'URL' and 'REST' arguments will normally be added by the
24 The CGI script is called with its own filename as the first and only
25 command-line parameter.
32 Change directory to the directory containing the CGI script
33 before running it. This behavior is encouraged by the CGI
34 specification, but is not used by *callcgi* by default.
38 Call 'PROGRAM' instead of the file itself. This mechanism can
39 be used to serve e.g. PHP scripts and other programs that have
40 an interpreter that can act as a CGI script. The filename of
41 the actual script is still passed as the first and only
42 command-line parameter to the program.
46 Fredrik Tolf <fredrik@dolda2000.com>
50 *dirplex*(1), *ashd*(7), *callscgi*(1), *callfcgi*(1), RFC 3875