[Fai-commit] r3687 - in trunk: bin conf lib

fai-commit at lists.alioth.debian.org fai-commit at lists.alioth.debian.org
Thu Jul 27 11:01:12 UTC 2006


Author: lange
Date: 2006-07-27 11:01:11 +0000 (Thu, 27 Jul 2006)
New Revision: 3687

Modified:
   trunk/bin/fai-setup
   trunk/conf/fai.conf
   trunk/lib/fai-savelog
   trunk/lib/subroutines-linux
Log:
remove FAI_REMOTESH and FAI_REMOTECP from fai.conf, use FAI_LOGPROTO instead


Modified: trunk/bin/fai-setup
===================================================================
--- trunk/bin/fai-setup	2006-07-27 10:39:05 UTC (rev 3686)
+++ trunk/bin/fai-setup	2006-07-27 11:01:11 UTC (rev 3687)
@@ -82,7 +82,7 @@
 	exit 8
     fi
 
-    if [ $FAI_REMOTESH = "ssh" -o $FAI_REMOTECP = "scp" ]; then
+    if [ $FAI_LOGPROTO= "ssh" ]; then
 	# set up ssh on the server
 	mkdir -p -m 700 $loguserhome/.ssh
 	
@@ -117,7 +117,7 @@
 	chmod 0700 $sshdir/authorized_keys
 	echo "$sshdir/authorized_keys created."
     fi
-    if [ $FAI_REMOTESH = "rsh" -o $FAI_REMOTECP = "rcp" ]; then
+    if [ $FAI_LOGPROTO= "rsh" ]; then
 	# use .rhosts authentication
 	echo "+ at faiclients root" > $loguserhome/.rhosts
 	chmod go-rwx $loguserhome/.rhosts

Modified: trunk/conf/fai.conf
===================================================================
--- trunk/conf/fai.conf	2006-07-27 10:39:05 UTC (rev 3686)
+++ trunk/conf/fai.conf	2006-07-27 11:01:11 UTC (rev 3687)
@@ -28,13 +28,9 @@
 # g+w /srv/tftp/fai. If the variable is undefined, this feature is disabled.
 # Define it, to enable it, eg. LOGUSER=fai
 LOGUSER=
-# use ssh or rsh for copying log files to user fai and for logging in
-# from install clients to install server
-FAI_REMOTESH=rsh
-FAI_REMOTECP=rcp
 
-# set protocol type for saving logs, default is rcp/scp. Set to ftp if desired.
-FAI_LOGPROTO=
+# set protocol type for saving logs. Values: ssh, rsh, ftp
+FAI_LOGPROTO=rsh
 # Name of log-server. If undefined, the install server will be used. 
 LOGSERVER=
 # writable directory on remote server, when using FTP protocol

Modified: trunk/lib/fai-savelog
===================================================================
--- trunk/lib/fai-savelog	2006-07-27 10:39:05 UTC (rev 3686)
+++ trunk/lib/fai-savelog	2006-07-27 11:01:11 UTC (rev 3687)
@@ -6,7 +6,7 @@
 # fai-save-log -- save log files from fai to a local or remote location
 #
 # This script is part of FAI (Fully Automatic Installation)
-# (c) 2002-2005 by Thomas Lange, lange at informatik.uni-koeln.de
+# (c) 2002-2006 by Thomas Lange, lange at informatik.uni-koeln.de
 # Universitaet zu Koeln
 #
 #*********************************************************************
@@ -76,8 +76,14 @@
 	    fai-savelog-ftp ;;
         none)
             echo "Don't save logs with remote method, only local storage." ;;
-        *)
+        ssh)
+	    export FAI_REMOTESH=ssh
+	    export FAI_REMOTECP=scp
 	    save_log_remote_shell ;;
+        rsh)
+	    export FAI_REMOTESH=rsh
+	    export FAI_REMOTECP=rcp
+	    save_log_remote_shell ;;
     esac
 }
 # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Modified: trunk/lib/subroutines-linux
===================================================================
--- trunk/lib/subroutines-linux	2006-07-27 10:39:05 UTC (rev 3686)
+++ trunk/lib/subroutines-linux	2006-07-27 11:01:11 UTC (rev 3687)
@@ -220,6 +220,12 @@
     local doexit=0
     local hostname=$(hostname)
     local ipaddr=$(grep IPADDR $LOGDIR/boot.log | cut -d\' -f2)
+
+    case "$FAI_LOGPROTO" in
+	ftp) export FAI_REMOTESH=ssh ;;
+	ssh) export FAI_REMOTESH=ssh ;;
+	rsh) export FAI_REMOTESH=rsh ;;
+    esac
     frsh="$FAI_REMOTESH -l $LOGUSER ${SERVER}"
 
     if [ -z "$SERVER" ] ; then




More information about the Fai-commit mailing list