On Tue, Aug 5, 2008 at 14:08, <[EMAIL PROTECTED]> wrote:
>
> Hi folks-
>
> I am implementing a new infrastructure. It consists of pre-dev, dev,
> staging, and production boxes behind F5's. I also implemented a Polyserve
> matrix over the SAN.
>
> That being said, what's everyone's take on shared binaries with the apache
> configs macro'd to the hostnames (including splitting of lock paths, logs,
> etc). Is there a module that allows for regex modification of variables
> (i.e., to make prod01,prod02,etc look for prod configs, etc).
On very flexible way to do this is to use mod_perl. You can then use
perl in your config. I for example have this in my config:
<Perl>
# We get the hostname, and use it to:
# generate a PID and lock file name
# generate log file names
use Sys::Hostname;
use Apache2::ServerUtil;
$hostname = hostname();
$PidFile = "logs/$hostname/httpd.pid";
$LockFile = "logs/$hostname/accept.lock";
my $serverroot = Apache2::ServerUtil::server_root() ;
unless ( -d "$serverroot/logs/$hostname" ) {
mkdir "$serverroot/logs/$hostname", 0755;
}
$CustomLog = "logs/$hostname/access.log" ;
$ErrorLog = "logs/$hostname/error.log" ;
</Perl>
More about this on the mod_perl homepage and here:
http://perl.apache.org/docs/2.0/api/Apache2/PerlSections.html
Krist
--
[EMAIL PROTECTED]
[EMAIL PROTECTED]
Bremgarten b. Bern, Switzerland
--
A: It reverses the normal flow of conversation.
Q: What's wrong with top-posting?
A: Top-posting.
Q: What's the biggest scourge on plain text email discussions?
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
" from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]