Config files for CGI::Application under mod_perl
Posted on 2004-08-02
I have a CGI::Application module running on Apache with mod_perl. The CGI::Application module is stored centrally, with the instance scripts located on multiple sub-sites. I want to be able to use different configuration files for the different instances. My current version has been written to just work correctly on a single one of our sub-sites and runs by using another package to load the configuration file into memory and to provide the relevant subroutines to extract the data (there is a system of defaults for many of the configuration settings, so the package has the ability to decide whether information has been set locally).
Has anyone got any suggestions on how I might be able to alter it in order to be able to use the modules centrally, then defining which configuration file (located in the sub-site) to use in the instance script?