Commit 30280f5c authored by Leigh Stoller's avatar Leigh Stoller

More FreeBSD 8.2 bits.

parent 7d8de97b
......@@ -682,8 +682,8 @@ ScriptAlias /cgi-bin/ "/usr/local/www/apache22/cgi-bin/"
#
# Mailman config stuff.
#
ScriptAlias /mailman/ /usr/lib/mailman/cgi-bin/
<Directory /usr/lib/mailman/cgi-bin/>
ScriptAlias /mailman/ /usr/local/mailman/cgi-bin/
<Directory /usr/local/mailman/cgi-bin/>
AllowOverride None
Options ExecCGI
Order allow,deny
......
......@@ -725,8 +725,8 @@ ScriptAlias /cgi-bin/ "/usr/local/www/apache22/cgi-bin/"
#
# Mailman config stuff.
#
ScriptAlias /mailman/ /usr/lib/mailman/cgi-bin/
<Directory /usr/lib/mailman/cgi-bin/>
ScriptAlias /mailman/ /usr/local/mailman/cgi-bin/
<Directory /usr/local/mailman/cgi-bin/>
AllowOverride None
Options ExecCGI
Order allow,deny
......
......@@ -778,27 +778,29 @@ Phase "patches", "Applying patches", sub {
ExecQuietFatal("$PATCH -f -l -p0 -i $patchfile");
};
}
Phase "Mysql.pm.patch", "Patching Mysql.pm", sub {
my $patchfile = $MYSQL_PM_PATCH;
$patchfile = `realpath $patchfile`;
chomp $patchfile;
my $dir;
foreach $prefix (@INC) {
if (-e "$prefix/Mysql.pm") {
$dir = $prefix;
last;
if ($FBSD_MAJOR < 7) {
Phase "Mysql.pm.patch", "Patching Mysql.pm", sub {
my $patchfile = $MYSQL_PM_PATCH;
$patchfile = `realpath $patchfile`;
chomp $patchfile;
my $dir;
foreach $prefix (@INC) {
if (-e "$prefix/Mysql.pm") {
$dir = $prefix;
last;
}
}
}
if (!defined($dir)) {
PhaseFail("Unable to find Mysql.pm");
}
if (!ExecQuiet("$PATCH -d $dir -C -f -l -R -i $patchfile")) {
PhaseSkip("Patch already applied");
}
ExecQuietFatal("$PATCH -d $dir -f -l -i $patchfile");
};
if (!defined($dir)) {
PhaseFail("Unable to find Mysql.pm");
}
if (!ExecQuiet("$PATCH -d $dir -C -f -l -R -i $patchfile")) {
PhaseSkip("Patch already applied");
}
ExecQuietFatal("$PATCH -d $dir -f -l -i $patchfile");
};
}
Phase "perlselfloaderpatch", "Fixing perl self-loader", sub {
my $perldir = "/usr/local/lib/perl5/5.10.1";
DoneIfDoesntExist("$perldir/SelfLoader.pm");
......@@ -1536,6 +1538,20 @@ Phase "sslcerts", "Setting up SSL certificates", sub {
" chmod 640 ${ETC_EMULAB_DIR}/${EMULAB_PEM}' ");
};
Phase "apache", "Setting up Apache on boss", sub {
Phase "dirs", "Creating SSL directories ", sub {
PhaseSucceed()
if (-d "$APACHE_ETCDIR/ssl.crt" &&
-d "$APACHE_ETCDIR/ssl.key");
if (! -d "$APACHE_ETCDIR/ssl.crt") {
mkdir "$APACHE_ETCDIR/ssl.crt", 0700 or
PhaseFail("Unable to create $APACHE_ETCDIR/ssl.crt : $!");
}
if (! -d "$APACHE_ETCDIR/ssl.key") {
mkdir "$APACHE_ETCDIR/ssl.key", 0700 or
PhaseFail("Unable to create $APACHE_ETCDIR/ssl.key : $!");
}
};
Phase "cert", "Installing Apache SSL certificate", sub {
DoneIfExists("$APACHE_CERTFILE");
ExecQuietFatal("$CP $TOP_OBJDIR/ssl/$APACHE_CERTPEM ".
......
......@@ -1011,7 +1011,7 @@ Phase "cron", "Adding cron jobs", sub {
my @cronlist = ("0 \t6\t*\t*\t*\troot\t$PREFIX/sbin/quotamail");
if ($WIKISUPPORT) {
push(@cronlist,
"*/15 \t*\t*\t*\t*\troot\t(cd /usr/local/www/data/twiki/bin;".
"*/15 \t*\t*\t*\t*\troot\t(cd $WWWDIR/twiki/bin;".
" ./mailnotify -q >> /var/tmp/mailnotify.log 2>&1)");
}
AppendToFileFatal($CRONTAB, @cronlist);
......@@ -1171,6 +1171,20 @@ Phase "apache", "Installing apache config file", sub {
DoneIfEdited("$HTTPD_CONF");
ExecQuietFatal("$GMAKE -C $TOP_OBJDIR/apache control-install");
};
Phase "dirs", "Creating Apache SSL directories ", sub {
PhaseSucceed()
if (-d "$APACHE_ETCDIR/ssl.crt" &&
-d "$APACHE_ETCDIR/ssl.key");
if (! -d "$APACHE_ETCDIR/ssl.crt") {
mkdir "$APACHE_ETCDIR/ssl.crt", 0700 or
PhaseFail("Unable to create $APACHE_ETCDIR/ssl.crt : $!");
}
if (! -d "$APACHE_ETCDIR/ssl.key") {
mkdir "$APACHE_ETCDIR/ssl.key", 0700 or
PhaseFail("Unable to create $APACHE_ETCDIR/ssl.key : $!");
}
};
Phase "php.ini", "Installing php.ini file", sub {
DoneIfEdited($PHP_INI);
ExecQuietFatal("$GMAKE -C $TOP_OBJDIR/apache install-php-ini");
......@@ -1182,6 +1196,10 @@ Phase "wikidocs", "Installing wikidocs redirect", sub {
DoneIfExists("$WWWDIR/wikidocs/.htaccess");
if (! -e "$WWWDIR") {
mkdir("$WWWDIR", 0755) or
PhaseFail("Unable to make $WWWDIR: $!");
}
if (! -e "$WWWDIR/wikidocs") {
mkdir("$WWWDIR/wikidocs", 0755) or
PhaseFail("Unable to make $WWWDIR/wikidocs: $!");
......@@ -1405,7 +1423,7 @@ if ($CVSSUPPORT) {
if ($BUGDBSUPPORT) {
my $FLYSPRAYPWD = "$ETCDIR/flyspray.pwd";
my $FLYSPRAYDIR = "/usr/local/www/data/flyspray";
my $FLYSPRAYDIR = "$WWWDIR/flyspray";
my $FLYSPRAYURL = "http://$OUTER_BOSS/downloads/flyspray-0.9.9.tgz";
my $FLYSPRAYCONF = "$ETCDIR/flyspray.conf.php";
my $PHPCONFIG = $PHP_INI;
......@@ -1535,7 +1553,7 @@ if ($BUGDBSUPPORT) {
}
if ($WIKISUPPORT) {
my $WIKIDIR = "/usr/local/www/data/twiki";
my $WIKIDIR = "$WWWDIR/twiki";
my $WIKICONF = "LocalSite.cfg";
my $WIKIURL = "http://$OUTER_BOSS/downloads/twiki-4.1.tgz";
my $localtarfile = "/tmp/twiki.tgz";
......
......@@ -3,6 +3,7 @@
# Wrapper for DHCPD which has a habit of dying.
#
elabinelab="@ELABINELAB@"
configfile="/usr/local/etc/dhcpd.conf"
case "$1" in
start)
# limit to control network
......@@ -13,7 +14,7 @@ case "$1" in
if [ -x @prefix@/sbin/daemon_wrapper ]; then
echo -n " dhcpd wrapper"
@prefix@/sbin/daemon_wrapper \
/usr/local/sbin/dhcpd -f $cnetif
/usr/local/sbin/dhcpd -f $cnetif -cf $configfile
fi
;;
stop)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment