Config path override
Use a custom lazysite.conf path via command-line arg or environment variable.
Config path override
Override the default lazysite.conf location using a command-line
argument or environment variable. Useful for staging environments,
testing alternate configs, or deployments where the conf lives
outside the docroot.
Most sites do not need this. Each Apache vhost has its own
DOCUMENT_ROOT, so each site automatically gets its own
lazysite.conf at DOCROOT/lazysite/lazysite.conf. Multiple
sites on one server each have their own docroot and their own
config - no override is needed.
Priority order
--conf PATHcommand-line argument (highest priority)LAZYSITE_CONFenvironment variable- Default:
DOCROOT/lazysite/lazysite.conf
Syntax
Command-line:
perl cgi-bin/lazysite-processor.pl --conf /path/to/custom.conf
Environment variable:
LAZYSITE_CONF=/path/to/custom.conf
Example
Test with a different configuration:
LAZYSITE_CONF=/tmp/test.conf \
DOCUMENT_ROOT=/var/www/html \
REDIRECT_URL=/index \
perl cgi-bin/lazysite-processor.pl
Notes
- The path is used as-is - it is not resolved relative to the docroot
- If the specified file does not exist, site variables will be empty
(no error is raised -
resolve_site_varsreturns early) - The
--confargument requires the path as the next argument (space-separated, not=) - lazysite.conf - configuration file format