💡 /cgi-bin/
Venerable hosting providers may require CGIs[1] to be inside a /cgi-bin/
directory or refuse
execution. However, this directory will not serve assets like css or image files. Since #Seppo
wants to unpack files and store data next to itself, extra measures must be taken for those
providers:
Redirect to /cgi-bin/
In order for the webserver to serve seppo.cgi
from inside
/cgi-bin/
but the assets from outside, a configuration is needed.
Put that as is into the .htaccess
in your webroot (next to
/cgi-bin/
):
RewriteEngine On
# https://Seppo.Social/S1037
RewriteCond %{REQUEST_URI} !^/cgi-bin/
RewriteRule "seppo\.cgi" "/cgi-bin%{REQUEST_URI}" [passthrough,last]
Place seppo.cgi
#Seppo has to seize control over the directory it sits in. If this happens to be your
webroot already having a configuration, you may want to put #Seppo into a subdirectory, e.g.
https://example.com/subdirectory/seppo.cgi
:
- put
seppo.cgi
into/cgi-bin/subdirectory/
and - create an additional empty twin
/subdirectory/
outside/cgi-bin/
.
This way seppo.cgi
knows, that it should pretend running inside
/subdirectory/
. And because #Seppo is reluctant to modify anything outside it's
realm, you have to do that explicitly.