[LON-CAPA-cvs] cvs: loncom / lond

foxr lon-capa-cvs@mail.lon-capa.org
Tue, 19 Aug 2003 10:46:14 -0000


foxr		Tue Aug 19 06:46:14 2003 EDT

  Modified files:              
    /loncom	lond 
  Log:
  Added skeletal (non functioning) command processing for new encoded requests:
  - pushfile:tablenam:tablecontents
     Pushes a new version of an administrative file in lonTabs.
     tablename - can be any of host or domain and 
     tablecontents -  are the contents
                 of the new version of the file.  
     The old file is replaced by the new file with a backup of the old file
     rotated into tablenam.old[0-9]. Maintaining 10 backups of the old file.
  - reinit:process
     Reinitializes 'process' where:
     process - can be either lond or lonc.  The hosts file is read.
       processes for any hosts no longer in the hosts file are killed.
       processes for any hosts that are new in the hosts file are started up.
       processes that already exist for hosts in the hosts file are left alone.
  
  
  
  
  
Index: loncom/lond
diff -u loncom/lond:1.136 loncom/lond:1.137
--- loncom/lond:1.136	Tue Aug 12 15:46:04 2003
+++ loncom/lond	Tue Aug 19 06:46:14 2003
@@ -2,7 +2,7 @@
 # The LearningOnline Network
 # lond "LON Daemon" Server (port "LOND" 5663)
 #
-# $Id: lond,v 1.136 2003/08/12 19:46:04 www Exp $
+# $Id: lond,v 1.137 2003/08/19 10:46:14 foxr Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -81,7 +81,7 @@
 my $status='';
 my $lastlog='';
 
-my $VERSION='$Revision: 1.136 $'; #' stupid emacs
+my $VERSION='$Revision: 1.137 $'; #' stupid emacs
 my $remoteVERSION;
 my $currenthostid;
 my $currentdomainid;
@@ -652,7 +652,7 @@
 		   if ($userinput =~ /^ping/) {
                        print $client "$currenthostid\n";
 # ------------------------------------------------------------------------ pong
-		   } elsif ($userinput =~ /^pong/) {
+		   }elsif ($userinput =~ /^pong/) {
                        my $reply=&reply("ping",$hostid{$clientip});
                        print $client "$currenthostid:$reply\n"; 
 # ------------------------------------------------------------------------ ekey
@@ -683,6 +683,10 @@
 		   } elsif ($userinput =~ /^userload/) {
 		       my $userloadpercent=&userload();
 		       print $client "$userloadpercent\n";
+
+#
+#        Transactions requiring encryption:
+#
 # ----------------------------------------------------------------- currentauth
 		   } elsif ($userinput =~ /^currentauth/) {
 		     if ($wasenc==1) {
@@ -697,6 +701,12 @@
 		     } else {
 		       print $client "refused\n";
 		     }
+#--------------------------------------------------------------------- pushfile
+		   } elsif($userinput =~ /^pushfile/) { 
+		       print $client "ok\n";
+#--------------------------------------------------------------------- reinit
+		   } elsif($userinput =~ /^reinit/) {
+		       print $client "ok\n";
 # ------------------------------------------------------------------------ auth
                    } elsif ($userinput =~ /^auth/) {
 		     if ($wasenc==1) {