update to db59a1a2dd 2019-03-07
[automated-distro-installer] / fai / config / files / etc / rc.local / FAISERVER
index 8710678a1991c0e1c8dc575e15754dd6b4307d25..e70fae952205b7e5689cd19881a7e745060faa04 100755 (executable)
@@ -33,7 +33,7 @@ if [ ! -d "$FAI_CONFIGDIR/class" ]; then
     mkdir -p $FAI_CONFIGDIR
     cp -a /usr/share/doc/fai-doc/examples/simple/* $FAI_CONFIGDIR
     ainsl /srv/fai/config/class/FAIBASE.var "^LOGUSER=fai"
-    myip=$(ip addr show up| grep -w inet | cut -d t -f 2 | cut -d ' ' -f 2 | cut -d / -f 1 | grep -v 127.0.0.1)
+    myip=$(ip addr show up| grep -P -o '(?<=inet )[^/]+' | grep -v 127.0.0.1)
     echo "APTPROXY=http://$myip:3142" >> /srv/fai/config/class/DEBIAN.var
 fi
 # set the LOGUSER, wo we get all the logs from our install clients
@@ -79,7 +79,7 @@ EOF
 fai-chboot -o default
 
 # create a template for booting the installation
-fai-chboot -Iv -f verbose,sshd,createvt,menu -u nfs://faiserver/srv/fai/config stretch.tmpl
+fai-chboot -Iv -f verbose,sshd,createvt,menu -u nfs://faiserver/srv/fai/config buster.tmpl
 
 # Since we do not know the MAC address, our DHCP cannot provide the hostname.
 # Therefore we do explicitly set the hostname