[Catalyst] Deployment: Dev/Testing/Staging/Production

Peter Edwards peter at dragonstaff.com
Sat May 20 17:52:33 CEST 2006


I wrote a utility for managing an OpenInteract based app running various
servers. That might give you a starting point unless someone else already
has a nice Catalyst web server setup utility.

I found the easiest way was to hold the backend server list and vhost
mappings in an SQL table and use a utility to 
a) write the Apache config files
b) start/stop servers, keeping track of what was running.
Using apachectl got too cumbersome.

The setup was:
Access by hostname -> Proxy apache -> Backend server at specified port

So:
Proxy apache     ->   multiple backend servers,
SSL proxy apache ->   one for each application area


Under http://perl.dragonstaff.com/om-0.2/
src/oiapachectl.pl is the utility
src/sys.sql contains some DDL
src/apacheconf.tgz are some Apache 1 config files; they Include in from a
separate vhost conf that can be overwritten from the utility.
These are templated because they were part of an install pack, so you need
to replace <%somevarname%> with your values.

You'd need to make quite a few changes to suit it to your setup but it's a
start.

Regards, Peter

-----Original Message-----
From: catalyst-bounces at lists.rawmode.org
[mailto:catalyst-bounces at lists.rawmode.org] On Behalf Of Bill Moseley
Sent: 20 May 2006 15:29
To: catalyst at lists.rawmode.org
Subject: [Catalyst] Deployment: Dev/Testing/Staging/Production

Anyone have a nice real-world setup for managing different application
configurations?

My application runs in four modes:

I use $app_server.pl for development, and then I have frontend/backend
apache and mod_perl servers for testing (on dev machine), staging
(on hardware that matches production), and the production setup.

Running the dev server is easy since Catalyst knows which Engine it
is using and I can test that when needed.

But, for the Apache configurations I have a two shell scripts, one for
the front-end apache, and one for the back-end mod_perl. The shell
scripts pass -D settings to httpd.conf to set Listen, ServerRoot,
DocRoot, mod_disk_cache location and SSL config.  The back-end
mod_perl server should be easier, but it has to tell Catalyst the
hostnames & ports of the front-end server SSL and non-SSL server (so
C::P::RequireSSL can do its thing), and has to know which database to
use.

I'm planning on changing things a bit and use separate
dev/testing/staging/production directories to hold the configuration
files.  But, I thought it good to ask here first.

Does anyone have a nice clever setup for managing these configs?


-- 
Bill Moseley
moseley at hank.org


_______________________________________________
Catalyst mailing list
Catalyst at lists.rawmode.org
http://lists.rawmode.org/mailman/listinfo/catalyst





More information about the Catalyst mailing list