From a74319598f73b0be009f2920d198d40929123303 Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Fri, 17 Sep 2010 02:59:25 +0200 Subject: [PATCH] doc: Added a manpage for callcgi. --- doc/callcgi.doc | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 doc/callcgi.doc diff --git a/doc/callcgi.doc b/doc/callcgi.doc new file mode 100644 index 0000000..4564279 --- /dev/null +++ b/doc/callcgi.doc @@ -0,0 +1,50 @@ +callcgi(1) +========== + +NAME +---- +callcgi - CGI request handler for ashd(7) + +SYNOPSIS +-------- +*callcgi* [*-c*] [*-p* 'PROGRAM'] 'METHOD' 'URL' 'REST' + +DESCRIPTION +----------- + +*callcgi* serves CGI scripts by translating the *ashd*(7) request +environment into a standard CGI environment and executing the target +file. It needs to be called with the `X-Ash-File` header added to the +request, as *dirplex*(1) does. + +*callcgi* is a transient handler, as defined in *ashd*(7), and the +'METHOD', 'URL' and 'REST' arguments will normally be added by the +parent handler. + +The CGI script is called with its own filename as the first and only +command-line parameter. + +OPTIONS +------- + +*-c*:: + + Change directory to the directory containing the CGI script + before running it. This behavior is encouraged by the CGI + specification, but is not used by *callcgi* by default. + +*-p* 'PROGRAM':: + + Call 'PROGRAM' instead of the file itself. This mechanism can + be used to serve e.g. PHP scripts and other programs that have + an interpreter that can act as a CGI script. The filename of + the actual script is still passed as the first and only + command-line parameter to the program. + +AUTHOR +------ +Fredrik Tolf + +SEE ALSO +-------- +*dirplex*(1), *ashd*(7), RFC 3875 -- 2.11.0