[Socialtext-commits] SF.net SVN: socialtext: [985] branches/rug
Brought to you by:
socialtextrocks
|
From: <pet...@us...> - 2007-01-30 02:36:10
|
Revision: 985
http://svn.sourceforge.net/socialtext/?rev=985&view=rev
Author: petdance
Date: 2007-01-29 18:36:07 -0800 (Mon, 29 Jan 2007)
Log Message:
-----------
fixing up short names
Modified Paths:
--------------
branches/rug/dev-bin/gen-config
branches/rug/etc/init.d/st-apache.in
Modified: branches/rug/dev-bin/gen-config
===================================================================
--- branches/rug/dev-bin/gen-config 2007-01-30 01:58:30 UTC (rev 984)
+++ branches/rug/dev-bin/gen-config 2007-01-30 02:36:07 UTC (rev 985)
@@ -454,8 +454,12 @@
my $confd = "$dirs{apache_app_etc}/conf.d";
my %config = standard_params( \%dirs );
+
+ # XXX Hoist into a module
my $webapi = get_build_setting( 'webapi' );
+ my $short_name = $webapi eq 'mod_perl1' ? 'apache-perl' : 'apache2';
+
%config = (
%config,
base_dir => $dirs{apache_app_root},
@@ -471,7 +475,7 @@
apache_proxy_etc_dir => $dirs{apache_app_etc},
use_ssl => _use_ssl($config{nlw_server_hostname}),
),
- module_dir => get_build_setting( $webapi eq 'mod_perl1' ? 'apache-perl-moduledir' : 'apache2-moduledir' ),
+ module_dir => get_build_setting( "$short_name-moduledir" ),
nlw_config_file => File::Spec->catfile( $dirs{socialtext_etc}, 'socialtext.conf' ),
log_prefix => 'nlw',
servers => {
@@ -484,7 +488,7 @@
'apache-proxy' => $opts{'apache-proxy'},
single => $single,
nlw_server_aliases => [],
- apache_short_name => 'apache-perl',
+ apache_short_name => $short_name,
use_canonical_name => 'On',
);
$config{backend_port} = $single ? $config{apache_proxy_port} : $config{apache_app_port};
Modified: branches/rug/etc/init.d/st-apache.in
===================================================================
--- branches/rug/etc/init.d/st-apache.in 2007-01-30 01:58:30 UTC (rev 984)
+++ branches/rug/etc/init.d/st-apache.in 2007-01-30 02:36:07 UTC (rev 985)
@@ -8,16 +8,21 @@
use Carp 'croak';
use Readonly;
+use Socialtext::Build qw( get_build_setting );
use Socialtext::InitFunctions qw(
fork_and_exec_daemon_as_user system_or_die try_kill timeout_waitpid
succeed fail restart
);
+# XXX Hoist into a module
+my $webapi = get_build_setting( 'webapi' );
+my $short_name = $webapi eq 'mod_perl1' ? 'apache-perl' : 'apache2';
+
Readonly my $NAME => 'st-apache';
Readonly my $CONF => '@PREFIX@@HTTPD_CONFDIR@/st-httpd.conf';
Readonly my $DAEMON => '@HTTPD@';
Readonly my @COMMAND => ($DAEMON, '-f', $CONF);
-Readonly my $PIDFILE => '@PREFIX@@HTTPD_PIDDIR@/st-apache.pid';
+Readonly my $PIDFILE => "@PREFIX@@HTTPD_PIDDIR@/$short_name.pid";
Readonly my $PERL => '@PERL@';
Readonly my $USER => 'root';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|