[Fai-commit] r3916 - trunk/bin

fai-commit at lists.alioth.debian.org fai-commit at lists.alioth.debian.org
Mon Sep 11 15:05:05 UTC 2006


Author: lange
Date: 2006-09-11 15:05:04 +0000 (Mon, 11 Sep 2006)
New Revision: 3916

Modified:
   trunk/bin/fai-cd
Log:
use $FAI instead of /fai


Modified: trunk/bin/fai-cd
===================================================================
--- trunk/bin/fai-cd	2006-09-11 15:04:44 UTC (rev 3915)
+++ trunk/bin/fai-cd	2006-09-11 15:05:04 UTC (rev 3916)
@@ -116,7 +116,7 @@
 
     set +e
     local d
-    local dirs="boot fai media/mirror etc/apt/sources.list"
+    local dirs="boot $FAI media/mirror etc/apt/sources.list"
     for d in $dirs; do
 	umount $NFSROOT/$d 2>/dev/null
     done
@@ -131,7 +131,7 @@
 
     mkdir -p $NFSROOT/media/mirror
     mount --bind $tmp/boot $NFSROOT/boot
-    mount --bind $FAI_CONFIGDIR $NFSROOT/fai && echo "Config space $FAI_CONFIGDIR mounted"
+    mount --bind $FAI_CONFIGDIR $NFSROOT/$FAI && echo "Config space $FAI_CONFIGDIR mounted"
     mount --bind $mirrordir $NFSROOT/media/mirror && echo "Mirror $mirrordir mounted"
 # TODO: customize /etc/apt, copy apt preferences etc.
 
@@ -194,13 +194,15 @@
 
 [ -x "$(which mkinitrd-cd)" ] || die 7 "mkinitrd-cd not found. Please install package."
 [ -x "$(which mkisofs)" ] || die 8 "mkisofs not found. Please install package."
-[ -d "$NFSROOT/etc/fai" ] || die 10 "Please create NFSROOT by calling make-fai-nfsroot or fai-setup."
 
 [ -z "$cfdir" ] && cfdir=/etc/fai
 [ ! -d "$cfdir" ] && die 17 "$cfdir is not a directory."
 [ "$verbose" ] && echo "Using configuration files from directory $cfdir"
 . $cfdir/fai.conf
+export NFSROOT=$(source $cfdir/make-fai-nfsroot.conf; echo $NFSROOT)
+[ -d "$NFSROOT/etc/fai" ] || die 10 "Please create NFSROOT by calling make-fai-nfsroot or fai-setup."
 
+
 if [ -z "$grub_config" ]; then
     grub_config="$cfdir/menu.lst"
 else




More information about the Fai-commit mailing list