Installing ST requires:
The primary ST code base is in an XHier package, on capo.private. Thus distribution paths are needed from there to the WWW server(s) and MX handler(s) involved.
Making the CGIs (there are 3 versions) visible on a WWW server can be done in two different ways. www.math does it one way, and www.cs does it another (sigh).
One www.math, the WWW server configuration maps the expected ST URLs
https://www.math.uwaterloo.ca/mfcf/help/request
https://www.math.uwaterloo.ca/mfcf/help/request_beta
https://www.math.uwaterloo.ca/mfcf/help/request_debug
to corresponding locations in the ST package:
/software/rt-math-1/data/cgi-bin/request
/software/rt-math-1/data/cgi-bin/request_beta
/software/rt-math-1/data/cgi-bin/request_debug
each of which is a symbolic link to the corresponding setuid covers:
/software/rt-math-1/servers/st-suid-perl
/software/rt-math-1/servers/st-suid-perl_beta
/software/rt-math-1/servers/st-suid-perl_debug
As of 2015-11, the configuration in
www.math:/.software/regional/wwwdata_math.uwaterloo.ca/config/apache2/httpd.virtual.conf
is
# Request Tracker installation
<Directory /software/rt-math-1/data/cgi-bin>
Order allow,deny
Allow from all
</Directory>
# Enable $REMOTE_USER for RT access (RT#74607)
<LocationMatch ^/mfcf/help/request(_.*)?($|/)>
PerlAuthenHandler Apache::AuthenURL
require valid-user
</LocationMatch>
# URLs with "request" use $REMOTE_USER
ScriptAliasMatch /mfcf/help/request((_.*)?)((/.*)?)$ /software/rt-math-1/data/cgi-bin/request$1$3
<Directory /software/rt-math-1/data/images>
Order allow,deny
Allow from all
</Directory>
Alias /mfcf/help/images /software/rt-math-1/data/images
The Alias for /mfcf/help/images is obsolete (not needed).
An alternative, used on www.cs, is to place the CGIs where the URLs
https://cs.uwaterloo.ca/cscf/internal/request
https://cs.uwaterloo.ca/cscf/internal/request_beta
https://cs.uwaterloo.ca/cscf/internal/request_debug
/.software/regional/odyssey_apache/data/vhosts/cs.uwaterloo.ca/cscf/internal/
The CGIs must be setuid to run (a requirement of WWW server configuration).
One might think that they only need to be symbolic links to the
corresponding st-suid-perl
programs,
however the WWW server constraints on CGI symbolic links are
being dodged by using setuid cover scripts that invoke
st-suid-perl
.
E.g. request_beta
is (as of 2015-11)
#!/bin/sh
#
# Emulate this being a symlink to st-suid-perl_beta,
# to dodge www server symlink requirements.
#
SUID=/software/rt-math-1/servers/st-suid-perl_beta
# dodge execshell bug
export SHELL=/bin/sh
exec /software/mfcf-misc/bin/execshell $SUID request_beta "$@"
The scripts are setuid "rt", although they could be setuid to anything, as they invoke a setuid "root" program that implements the CGI. WARNING: the WWW server requires that the containing directory be owned by whatever the scripts are setuid to.
Aside from the main CGI, ST has other parts, such as:
They are expected to reside at a URL that replaces
E.g. given https://cs.uwaterloo.ca/cscf/internal/request as the main CGI, it is required that https://cs.uwaterloo.ca/cscf/internal/ST/production/ exist.
This With This request ST/production/ request_beta ST/beta/ request_debug ST/debug/
Relative to those URLs it is expected to find:
This Here From documentation .../doc/ /software/rt-math-1/doc/version/ images .../images /software/rt-math-1/data/images/ st-args.cgi .../st-args.cgi /software/rt-math-1/servers/st-args.cgi
st-args.cgi
is a CGI used by the debug version of the RunOn Sentence
to display the arguments that would be passed to the main CGI.
It appears in the above locations by doing what's in
.../ST/.ReadMe, which is executable (!).
This was done rather than fight the WWW server rules about symlinks.
With sufficient work, all of .../ST/ could be parameterized, so that it would work on both www.cs and www.math, with the source form in /software/rt-math-1/data/www-content/ (for example), as the only difference between the two is CSCF vs MFCF references.