Documentation ¶
Index ¶
- func GeminiCGIDirectory(pathRoot, fsRoot string) sr.Handler
- func GopherCGIDirectory(pathRoot, fsRoot string) sr.Handler
- func ResolveCGI(requestPath, fsRoot string) (string, string, error)
- func RunCGI(ctx context.Context, request *sr.Request, executable string, pathInfo string) (io.Reader, int, error)
- func SpartanCGIDirectory(pathRoot, fsRoot string) sr.Handler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GeminiCGIDirectory ¶
GeminiCGIDirectory runs any executable files relative to a root directory on the file system.
It will also find and run any executables _part way_ through the path, so for example a request for /foo/bar/baz can also run an executable found at /foo or /foo/bar. In such a case the PATH_INFO environment variable will include the remaining portion of the URI path.
func GopherCGIDirectory ¶
GopherCGIDirectory runs any executable files relative to a root directory on the file system.
It will also find and run any executables part way through the path, so for example a request for /foo/bar/baz can also run an executable found at /foo or /foo/bar. In such a case the PATH_INFO environment variable will include the remaining portion of the URI path.
func ResolveCGI ¶
ResolveCGI finds a CGI program corresponding to a request path.
It returns the path to the executable file and the PATH_INFO that should be passed, or an error.
It will find executables which are just part way through the path, so for example a request for /foo/bar/baz can run an executable found at /foo or /foo/bar. In such a case the PATH_INFO would include the remaining portion of the URI path.
func RunCGI ¶
func RunCGI( ctx context.Context, request *sr.Request, executable string, pathInfo string, ) (io.Reader, int, error)
RunCGI runs a specific program as a CGI script.
func SpartanCGIDirectory ¶
SpartanCGIDirectory runs executable files relative to a root directory in the file system.
It will also find any run any executable _part way_ through the path, so for example a request for /foo/bar/baz can also run an executable found at /foo or /foo/bar. In such a case the PATH_INFO environment variable will include the remaining portion of the URI.
Types ¶
This section is empty.