Releasing debian version 2.0~a5-1.
[live-boot-grml.git] / scripts / live
index a9c0f13..3e604f6 100755 (executable)
@@ -8,7 +8,7 @@ echo "/root/lib" >> /etc/ld.so.conf
 echo "/root/usr/lib" >> /etc/ld.so.conf
 
 mountpoint="/live/image"
-ext_mountpoint="/ext_volume"
+alt_mountpoint="/media"
 LIVE_MEDIA_PATH="live"
 
 root_persistence="live-rw"
@@ -34,9 +34,6 @@ then
        touch /etc/mtab
 fi
 
-[ -f /etc/live.conf ] && . /etc/live.conf
-export USERNAME USERFULLNAME HOSTNAME
-
 . /scripts/live-helpers
 
 if [ ! -f /live.vars ]
@@ -54,18 +51,14 @@ Arguments ()
                case "${ARGUMENT}" in
                        skipconfig)
                                NOACCESSIBILITY="Yes"
-                               NOAPTCDROM="Yes"
                                NOAUTOLOGIN="Yes"
                                NOCONSOLEKEYBOARD="Yes"
                                NOFASTBOOT="Yes"
                                NOFSTAB="Yes"
-                               NOHOSTS="Yes"
                                NONETWORKING="Yes"
-                               NOTIMEZONE="Yes"
                                NOXAUTOCONFIG="Yes"
-                               NOXAUTOLOGIN="Yes"
 
-                               export NOACCESSIBILITY NOAPTCDROM NOAUTOLOGIN NOCONSOLEKEYBOARD NOFASTBOOT NOFSTAB NOHOSTS NONETWORKING NOTIMEZONE NOXAUTOCONFIG NOXAUTOLOGIN
+                               export NOACCESSIBILITY NOAUTOLOGIN NOCONSOLEKEYBOARD NOFASTBOOT NOFSTAB NONETWORKING NOXAUTOCONFIG
                                ;;
 
                        access=*)
@@ -85,6 +78,17 @@ Arguments ()
                                set -x
                                ;;
 
+                       dhcp)
+                               # Force dhcp even while netbooting
+                               # Use for debugging in case somebody works on fixing dhclient
+                               DHCP="Force";
+                               export DHCP
+                               ;;
+
+                       nodhcp)
+                               unset DHCP
+                               ;;
+
                        ethdevice=*)
                                DEVICE="${ARGUMENT#ethdevice=}"
                                export DEVICE
@@ -125,18 +129,6 @@ Arguments ()
                                export FROMISO
                                ;;
 
-                       username=*)
-                               USERNAME="${ARGUMENT#username=}"
-                               LIVECONF="changed"
-                               export USERNAME LIVECONF
-                               ;;
-
-                       userfullname=*)
-                               USERFULLNAME="${ARGUMENT#userfullname=}"
-                               LIVECONF="changed"
-                               export USERFULLNAME LIVECONF
-                               ;;
-
                        ignore_uuid)
                                IGNORE_UUID="Yes"
                                export IGNORE_UUID
@@ -238,21 +230,11 @@ Arguments ()
                                export NOACCESSIBILITY
                                ;;
 
-                       noaptcdrom)
-                               NOAPTCDROM="Yes"
-                               export NOAPTCDROM
-                               ;;
-
                        noautologin)
                                NOAUTOLOGIN="Yes"
                                export NOAUTOLOGIN
                                ;;
 
-                       noxautologin)
-                               NOXAUTOLOGIN="Yes"
-                               export NOXAUTOLOGIN
-                               ;;
-
                        noconsolekeyboard)
                                NOCONSOLEKEYBOARD="Yes"
                                export NOCONSOLEKEYBOARD
@@ -268,11 +250,6 @@ Arguments ()
                                export NOFSTAB
                                ;;
 
-                       nohosts)
-                               NOHOSTS="Yes"
-                               export NOHOSTS
-                               ;;
-
                        nonetworking)
                                NONETWORKING="Yes"
                                export NONETWORKING
@@ -288,11 +265,6 @@ Arguments ()
                                export NOXAUTOCONFIG
                                ;;
 
-                       noxscreensaver)
-                               NOXSCREENSAVER="Yes"
-                               export NOXSCREENSAVER
-                               ;;
-
                        persistent)
                                PERSISTENT="Yes"
                                export PERSISTENT
@@ -339,25 +311,6 @@ Arguments ()
                                export NOPRESEED
                                ;;
 
-                       url=*)
-                               URL_LOCATION="${ARGUMENT#url=}"
-
-                               mount -o bind /sys /root/sys
-                               mount -o bind /proc /root/proc
-                               mount -o bind /dev /root/dev
-
-                               mkdir -p /root/var/run/network
-                               [ "${NETBOOT}" ] || chroot /root dhclient eth0
-                               chroot /root wget -P /tmp "${URL_LOCATION}"
-                               [ "${NETBOOT}" ] || chroot /root ifconfig eth0 down
-
-                               umount /root/sys
-                               umount /root/proc
-                               umount /root/dev
-
-                               LOCATIONS="/tmp/$(basename ${URL_LOCATION}) ${LOCATIONS}"
-                               ;;
-
                        */*=*)
                                question="${ARGUMENT%%=*}"
                                value="${ARGUMENT#*=}"
@@ -375,21 +328,6 @@ Arguments ()
                                export SILENT
                                ;;
 
-                       textonly)
-                               TEXTONLY="Yes"
-                               export TEXTONLY
-                               ;;
-
-                       timezone=*)
-                               TIMEZONE="${ARGUMENT#timezone=}"
-                               export TIMEZONE
-                               ;;
-
-                       notimezone)
-                               NOTIMEZONE="Yes"
-                               export NOTIMEZONE
-                               ;;
-
                        todisk=*)
                                TODISK="${ARGUMENT#todisk=}"
                                export TODISK
@@ -804,8 +742,8 @@ do_httpmount ()
                                iso|squashfs|tgz|tar)
                                        if [ "${extension}" = "iso" ]
                                        then
-                                               mkdir -p "${ext_mountpoint}"
-                                               dest="${ext_mountpoint}"
+                                               mkdir -p "${alt_mountpoint}"
+                                               dest="${alt_mountpoint}"
                                        else
                                                local dest="${mountpoint}/${LIVE_MEDIA_PATH}"
                                                mount -t ramfs ram "${mountpoint}"
@@ -859,10 +797,10 @@ do_httpmount ()
 
        if [ ${rc} != 0 ]
        then
-               if [ -d "${ext_mountpoint}" ]
+               if [ -d "${alt_mountpoint}" ]
                then
-                       umount "${ext_mountpoint}"
-                       rmdir "${ext_mountpoint}"
+                       umount "${alt_mountpoint}"
+                       rmdir "${alt_mountpoint}"
                fi
                umount "${mountpoint}"
        elif [ "${webfile}"  != "FETCH" ] ; then
@@ -1837,8 +1775,4 @@ mountroot ()
        exec 2>&7 7>&-
        kill ${tailpid}
        [ -w "${rootmnt}/var/log/" ] && cp live.log "${rootmnt}/var/log/" 2>/dev/null
-       if [ -f /etc/live.conf ]
-       then
-               cp /etc/live.conf "${rootmnt}/etc/"
-       fi
 }