[LON-CAPA-cvs] cvs: loncom / lond lonsql
raeburn
raeburn at source.lon-capa.org
Mon Nov 7 13:13:38 EST 2011
raeburn Mon Nov 7 18:13:38 2011 EDT
Modified files:
/loncom lond lonsql
Log:
- use lonDocRoot perlvar in place of static string: '/home/httpd/html'.
Index: loncom/lond
diff -u loncom/lond:1.483 loncom/lond:1.484
--- loncom/lond:1.483 Mon Oct 24 21:30:09 2011
+++ loncom/lond Mon Nov 7 18:13:37 2011
@@ -2,7 +2,7 @@
# The LearningOnline Network
# lond "LON Daemon" Server (port "LOND" 5663)
#
-# $Id: lond,v 1.483 2011/10/24 21:30:09 www Exp $
+# $Id: lond,v 1.484 2011/11/07 18:13:37 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -60,7 +60,7 @@
my $status='';
my $lastlog='';
-my $VERSION='$Revision: 1.483 $'; #' stupid emacs
+my $VERSION='$Revision: 1.484 $'; #' stupid emacs
my $remoteVERSION;
my $currenthostid="default";
my $currentdomainid;
@@ -6742,7 +6742,7 @@
my ($request, $domain, $user, $authtype) = @_;
# See if the request is of the form /$domain/_au
if($request =~ /^(\/\Q$domain\E\/_au)$/) { # It's an author rolesput...
- my $path="/home/httpd/html/priv/".$domain;
+ my $path=$perlvar{'lonDocRoot'}."/priv/$domain";
unless (-e $path) {
mkdir($path);
}
Index: loncom/lonsql
diff -u loncom/lonsql:1.90 loncom/lonsql:1.91
--- loncom/lonsql:1.90 Tue Mar 11 01:45:47 2008
+++ loncom/lonsql Mon Nov 7 18:13:38 2011
@@ -3,7 +3,7 @@
# The LearningOnline Network
# lonsql - LON TCP-MySQL-Server Daemon for handling database requests.
#
-# $Id: lonsql,v 1.90 2008/03/11 01:45:47 raeburn Exp $
+# $Id: lonsql,v 1.91 2011/11/07 18:13:38 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -233,13 +233,13 @@
system("echo 'Cannot connect to MySQL database!' |".
" mailto $emailto -s '$subj' > /dev/null");
- open(SMP,'>/home/httpd/html/lon-status/mysql.txt');
+ open(SMP,">$perlvar{'lonDocRoot'}/lon-status/mysql.txt");
print SMP 'time='.time.'&mysql=defunct'."\n";
close(SMP);
exit 1;
} else {
- unlink('/home/httpd/html/lon-status/mysql.txt');
+ unlink("$perlvar{'lonDocRoot'}/lon-status/mysql.txt");
$dbh->disconnect;
}
More information about the LON-CAPA-cvs
mailing list