[Catalyst-dev] several instances of an app on a machine.
Marcus Ramberg
marcus at nordaaker.com
Mon Mar 24 13:08:55 GMT 2008
Hi.
I've been thinking about a feature I want to add to Catalyst-Devel so
that
the created skeleton adds a new command to the script/ dir of apps
script/myapp.pl
Create an instance of Catalyst app installed somewhere in @INC
Make a directory structure like so:
myapp.conf
conf/apache-fastcgi.conf
conf/apache-modperl.conf
conf/lighttpd-fastcgi.conf
data/ - app specific data like a sqlite database or filecache to be
stored here
root/ - automagically added to the apps template path, so that
instances can override individual templates
script/server.pl - These should pretty much just proxy to the existing
scripts
script/fastcgi.pl so that they won't need to be upgraded.
It might also be sensible to do a simple change to Catalyst.pm in
Catalyst-Runtime:
Add a requires_instance() method to Catalyst.pm that will die with a
message
about having to run myapp.pl to create a instance of the app if it's
started
from the system instance or to set MYAPP_HOME in the case of modperl?
Thoughts/comments?
Marcus
More information about the Catalyst-dev
mailing list