summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/live171
-rwxr-xr-xscripts/live-bottom/02etc_live_conf4
-rwxr-xr-xscripts/live-bottom/02timezone60
-rwxr-xr-xscripts/live-bottom/05mountpoints36
-rwxr-xr-xscripts/live-bottom/06hostname62
-rwxr-xr-xscripts/live-bottom/08persistence_excludes4
-rwxr-xr-xscripts/live-bottom/10adduser127
-rwxr-xr-xscripts/live-bottom/12fstab4
-rwxr-xr-xscripts/live-bottom/14locales4
-rwxr-xr-xscripts/live-bottom/15autologin114
-rwxr-xr-xscripts/live-bottom/16umountfs4
-rwxr-xr-xscripts/live-bottom/19keyboard4
-rwxr-xr-xscripts/live-bottom/20xconfig6
-rwxr-xr-xscripts/live-bottom/21xdriver6
-rwxr-xr-xscripts/live-bottom/21xvidemode4
-rwxr-xr-xscripts/live-bottom/22gnome_panel_data39
-rwxr-xr-xscripts/live-bottom/22screensaver43
-rwxr-xr-xscripts/live-bottom/22serialtty4
-rwxr-xr-xscripts/live-bottom/22sslcert35
-rwxr-xr-xscripts/live-bottom/23etc_modules36
-rwxr-xr-xscripts/live-bottom/23networking6
-rwxr-xr-xscripts/live-bottom/24preseed25
-rwxr-xr-xscripts/live-bottom/25configure_init4
-rwxr-xr-xscripts/live-bottom/30accessibility4
-rwxr-xr-xscripts/live-bottom/31disable_update_notifier49
-rwxr-xr-xscripts/live-bottom/32disable_hibernation45
-rwxr-xr-xscripts/live-bottom/33enable_apport_crashes39
-rwxr-xr-xscripts/live-bottom/34disable_kaboom35
-rwxr-xr-xscripts/live-bottom/34disable_kde_services40
-rwxr-xr-xscripts/live-bottom/34disable_kpersonalizer54
-rwxr-xr-xscripts/live-bottom/35fix_language_selector44
-rwxr-xr-xscripts/live-bottom/36disable_trackerd38
-rwxr-xr-xscripts/live-bottom/41apt_cdrom4
-rwxr-xr-xscripts/live-bottom/43disable_updateinitramfs73
-rwxr-xr-xscripts/live-bottom/44pk_allow71
-rwxr-xr-xscripts/live-bottom/99hook50
-rw-r--r--scripts/live-functions21
-rw-r--r--scripts/live-helpers2
-rwxr-xr-xscripts/live-premount/modules4
-rwxr-xr-xscripts/live-premount/readonly2
40 files changed, 67 insertions, 1310 deletions
diff --git a/scripts/live b/scripts/live
index cbec764..4169c90 100755
--- a/scripts/live
+++ b/scripts/live
@@ -43,35 +43,6 @@ then
touch /live.vars
fi
-network_started=
-
-start_network ()
-{
- [ -z "$network_started" ] || return
- [ -z "$NETBOOT" ] || return
-
- mount -n -o bind /sys /root/sys
- mount -n -o bind /proc /root/proc
- mount -n -o bind /dev /root/dev
- mkdir -p /root/var/run/network
-
- # Close inherited fd's to prevent debconf-communicate from
- # continuing to run post-live-initramfs.
- chroot /root dhclient eth0 3>&- 4<&-
-
- network_started=1
-}
-
-stop_network ()
-{
- [ "$network_started" ] || return
-
- chroot /root ifconfig eth0 down
- umount /root/sys
- umount /root/proc
- umount /root/dev
-}
-
Arguments ()
{
PRESEEDS=""
@@ -82,31 +53,19 @@ Arguments ()
case "${ARGUMENT}" in
skipconfig)
NOACCESSIBILITY="Yes"
- NOAPPARMOR="Yes"
NOAPTCDROM="Yes"
NOAUTOLOGIN="Yes"
NOCONSOLEKEYBOARD="Yes"
NOFASTBOOT="Yes"
NOFSTAB="Yes"
- NOGNOMEPANEL="Yes"
NOHOSTS="Yes"
- NOJOCKEY="Yes"
- NOKPERSONALIZER="Yes"
- NOLANGUAGESELECTOR="Yes"
NOLOCALES="Yes"
NONETWORKING="Yes"
- NOPOLKITCONF="Yes"
- NOPOWERMANAGEMENT="Yes"
- NOPROGRAMCRASHES="Yes"
- NOSUDO="Yes"
NOTIMEZONE="Yes"
- NOUPDATENOTIFIER="Yes"
- NOUSER="Yes"
NOXAUTOCONFIG="Yes"
NOXAUTOLOGIN="Yes"
- NOXSCREENSAVER="Yes"
- export NOACCESSIBILITY NOAPPARMOR NOAPTCDROM NOAUTOLOGIN NOCONSOLEKEYBOARD NOFASTBOOT NOFSTAB NOGNOMEPANEL NOHOSTS NOJOCKEY NOKPERSONALIZER NOLANGUAGESELECTOR NOLOCALES NONETWORKING NOPOLKITCONF NOPOWERMANAGEMENT NOPROGRAMCRASHES NOSUDO NOTIMEZONE NOUPDATENOTIFIER NOUSER NOXAUTOCONFIG NOXAUTOLOGIN NOXSCREENSAVER
+ export NOACCESSIBILITY NOAPTCDROM NOAUTOLOGIN NOCONSOLEKEYBOARD NOFASTBOOT NOFSTAB NOHOSTS NOLOCALES NONETWORKING NOTIMEZONE NOXAUTOCONFIG NOXAUTOLOGIN
;;
access=*)
@@ -151,11 +110,6 @@ Arguments ()
export FORCEPERSISTENTFSCK
;;
- hook=*)
- HOOK="${ARGUMENT#hook=}"
- export HOOK
- ;;
-
ftpfs=*)
FTPFS="${ARGUMENT#ftpfs=}"
export FTPFS
@@ -166,12 +120,6 @@ Arguments ()
export HTTPFS
;;
- hostname=*)
- HOSTNAME="${ARGUMENT#hostname=}"
- LIVECONF="changed"
- export HOSTNAME LIVECONF
- ;;
-
isofrom=*|fromiso=*)
FROMISO="${ARGUMENT#*=}"
export FROMISO
@@ -301,11 +249,6 @@ Arguments ()
export NOACCESSIBILITY
;;
- noapparmor)
- NOAPPARMOR="Yes"
- export NOAPPARMOR
- ;;
-
noaptcdrom)
NOAPTCDROM="Yes"
export NOAPTCDROM
@@ -336,26 +279,11 @@ Arguments ()
export NOFSTAB
;;
- nognomepanel)
- NOGNOMEPANEL="Yes"
- export NOGNOMEPANEL
- ;;
-
nohosts)
NOHOSTS="Yes"
export NOHOSTS
;;
- nokpersonalizer)
- NOKPERSONALIZER="Yes"
- export NOKPERSONALIZER
- ;;
-
- nolanguageselector)
- NOLANGUAGESELECTOR="Yes"
- export NOLANGUAGESELECTOR
- ;;
-
nolocales)
NOLOCALES="Yes"
export NOLOCALES
@@ -366,41 +294,11 @@ Arguments ()
export NONETWORKING
;;
- nopowermanagement)
- NOPOWERMANAGEMENT="Yes"
- export NOPOWERMANAGEMENT
- ;;
-
- noprogramcrashes)
- NOPROGRAMCRASHES="Yes"
- export NOPROGRAMCRASHES
- ;;
-
- nojockey)
- NOJOCKEY="Yes"
- export NOJOCKEY
- ;;
-
- nosudo)
- NOSUDO="Yes"
- export NOSUDO
- ;;
-
swapon)
SWAPON="Yes"
export SWAPON
;;
- noupdatenotifier)
- NOUPDATENOTIFIER="Yes"
- export NOUPDATENOTIFIER
- ;;
-
- nouser)
- NOUSER="Yes"
- export NOUSER
- ;;
-
noxautoconfig)
NOXAUTOCONFIG="Yes"
export NOXAUTOCONFIG
@@ -460,8 +358,19 @@ Arguments ()
url=*)
URL_LOCATION="${ARGUMENT#url=}"
- start_network
+ 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}"
;;
@@ -538,11 +447,6 @@ Arguments ()
export UNIONTYPE
;;
- utc=*)
- UTC="${ARGUMENT#utc=}"
- export UTC
- ;;
-
xdebconf)
XDEBCONF="Yes"
export XDEBCONF
@@ -1088,7 +992,7 @@ find_snap ()
try_snap ()
{
# copy the contents of previously found snapshot to ${snap_mount}
- # and remember the device and filename for resync on exit in live-initramfs.init
+ # and remember the device and filename for resync on exit in live-boot.init
snapdata="${1}"
snap_mount="${2}"
@@ -1739,7 +1643,7 @@ find_livefs ()
then
# This is an ugly hack situation, the block device has
# an image directly on it. It's hopefully
- # live-initramfs, so take it and run with it.
+ # live-boot, so take it and run with it.
ln -s "${devname}" "${devname}.${fstype}"
echo "${devname}.${fstype}"
return 0
@@ -1907,35 +1811,12 @@ mountroot ()
mount -n -o bind /dev "${rootmnt}/dev"
fi
- # Open up two fifo's fd's for debconf-communicate to use. Speeds up
- # the live-initramfs process considerably.
- log_begin_msg "Creating debconf-communicate fifo mechanism"
- mkfifo /tmp/debconf-in.fifo
- mkfifo /tmp/debconf-out.fifo
-
- # Make the template database read-only, so that passthrough debconf
- # instances can write to it directly; otherwise templates are only
- # passed through when necessary. Use temporary config databases as
- # well; we'll copy their contents back at the end.
- DEBCONF_TMPDIR="$(chroot /root mktemp -dt debconf.XXXXXX)"
- cp -a /root/var/cache/debconf/config.dat "/root$DEBCONF_TMPDIR/"
- cp -a /root/var/cache/debconf/passwords.dat "/root$DEBCONF_TMPDIR/"
- sed "s,^Filename: /var/cache/debconf/\(config\|passwords\).dat$,Filename: $DEBCONF_TMPDIR/\1.dat,; /^Name: templatedb/a\
-Readonly: true" /root/etc/debconf.conf >"/root$DEBCONF_TMPDIR/debconf.conf"
-
- # Save the PID so it can be killed later.
- DEBCONF_SYSTEMRC="$DEBCONF_TMPDIR/debconf.conf" chroot /root debconf-communicate -fnoninteractive live-initramfs > /tmp/debconf-out.fifo < /tmp/debconf-in.fifo &
-
- if [ ! -p /tmp/debconf-in.fifo ] || [ ! -p /tmp/debconf-out.fifo ]
+ # Move to the new root filesystem so that programs there can get at it.
+ if [ ! -d /root/live/image ]
then
- log_warning_msg "failed to setup debconf-communicate channel"
+ mkdir -p /root/live/image
+ mount --move /live/image /root/live/image
fi
- log_end_msg
-
- # Order matters!
- # These file descriptors must stay open until we're finished with
- # debconf-communicate.
- exec 4</tmp/debconf-out.fifo 3>/tmp/debconf-in.fifo
maybe_break live-bottom
log_begin_msg "Running /scripts/live-bottom\n"
@@ -1948,20 +1829,6 @@ Readonly: true" /root/etc/debconf.conf >"/root$DEBCONF_TMPDIR/debconf.conf"
umount "${rootmnt}/dev"
fi
- # Close the fd's associated with debconf-communicate
- exec 3>&- 4<&-
- rm -f /tmp/debconf-in.fifo
- rm -f /tmp/debconf-out.fifo
-
- # Copy config database changes back to the master files.
- chroot /root debconf-copydb tmpdb config \
- --config=Name:tmpdb --config=Driver:File \
- --config="Filename:$DEBCONF_TMPDIR/config.dat"
- chroot /root debconf-copydb tmpdb passwords \
- --config=Name:tmpdb --config=Driver:File \
- --config="Filename:$DEBCONF_TMPDIR/passwords.dat"
- rm -rf "$DEBCONF_TMPDIR"
-
exec 1>&6 6>&-
exec 2>&7 7>&-
kill ${tailpid}
diff --git a/scripts/live-bottom/02etc_live_conf b/scripts/live-bottom/02etc_live_conf
index 815e379..8309a15 100755
--- a/scripts/live-bottom/02etc_live_conf
+++ b/scripts/live-bottom/02etc_live_conf
@@ -18,13 +18,13 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
. /scripts/live-functions
log_begin_msg "Copying config on real root fs"
-# live-initramfs script
+# live-boot script
if [ -f /etc/live.conf ]
then
diff --git a/scripts/live-bottom/02timezone b/scripts/live-bottom/02timezone
deleted file mode 100755
index 64faf3b..0000000
--- a/scripts/live-bottom/02timezone
+++ /dev/null
@@ -1,60 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOTIMEZONE}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Setting timezone"
-
-# live-initramfs script
-
-if [ -n "${TIMEZONE}" ]
-then
- area="$(echo ${TIMEZONE} | cut -f1 -d '/')"
- zone="$(echo ${TIMEZONE} | cut -f2 -d '/')"
-
-chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << EOF
-set tzdata/Areas ${area}
-set tzdata/Zones/${area} ${zone}
-EOF
-
- cp -f /root/usr/share/zoneinfo/${area}/${zone} /root/etc/localtime
-else
-
-chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << EOF
-set tzdata/Areas Etc
-set tzdata/Zones/Etc UTC
-EOF
-
- cp -f /root/usr/share/zoneinfo/UTC /root/etc/localtime
-fi
-
-if [ -n "${UTC}" ]
-then
- sed -i -e "s/UTC=.*/UTC=${UTC}/" /root/etc/default/rcS
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/05mountpoints b/scripts/live-bottom/05mountpoints
deleted file mode 100755
index ce151e1..0000000
--- a/scripts/live-bottom/05mountpoints
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Moving mount points"
-
-# live-initramfs script
-
-# Move to the new root filesystem so that programs there can get at it.
-if [ ! -d /root/live/image ]
-then
- mkdir -p /root/live/image
- mount --move /live/image /root/live/image
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/06hostname b/scripts/live-bottom/06hostname
deleted file mode 100755
index b14703a..0000000
--- a/scripts/live-bottom/06hostname
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOHOSTS}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Setting hostname"
-
-# live-initramfs script
-
-# Change hostname only if it is not set
-if [ ! -f /root/etc/hostname ] || grep -qs localhost\.localdomain /root/etc/hostname
-then
- echo "${HOSTNAME}" > /root/etc/hostname
-else
- HOSTNAME="$(cat /root/etc/hostname)"
- really_export HOSTNAME
-fi
-
-# Create /etc/hosts only if it is not present or empty
-if [ ! -s /root/etc/hosts ]
-then
- cat > /root/etc/hosts << EOF
-127.0.0.1 localhost
-127.0.1.1 ${HOSTNAME}
-
-# The following lines are desirable for IPv6 capable hosts
-::1 ip6-localhost ip6-loopback
-fe00::0 ip6-localnet
-ff00::0 ip6-mcastprefix
-ff02::1 ip6-allnodes
-ff02::2 ip6-allrouters
-ff02::3 ip6-allhosts
-EOF
-fi
-
-hostname "${HOSTNAME}"
-
-log_end_msg
diff --git a/scripts/live-bottom/08persistence_excludes b/scripts/live-bottom/08persistence_excludes
index b7aac92..43639f9 100755
--- a/scripts/live-bottom/08persistence_excludes
+++ b/scripts/live-bottom/08persistence_excludes
@@ -24,7 +24,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -z "${PERSISTENT}" ] || [ -n "${NOPERSISTENT}" ] || [ -z "${PERSISTENCE_IS_ON}" ] || [ ! -f /root/etc/live-persistence.binds ]
then
@@ -33,7 +33,7 @@ fi
. /scripts/live-functions
-# live-initramfs script
+# live-boot script
dirs="$(sed -e '/^ *$/d' -e '/^#.*$/d' /root/etc/live-persistence.binds | tr '\n' '\0')"
if [ -z "${dirs}" ]
diff --git a/scripts/live-bottom/10adduser b/scripts/live-bottom/10adduser
deleted file mode 100755
index 51868d4..0000000
--- a/scripts/live-bottom/10adduser
+++ /dev/null
@@ -1,127 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUSER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-load_confmodule
-
-log_begin_msg "Adding live session user"
-
-# live-initramfs script
-
-user_crypted="8Ab05sVQ4LLps" # as in $(echo "live" | mkpasswd -s)
-
-# U6aMy0wojraho is just a blank password
-db_set passwd/make-user true
-db_set passwd/root-password-crypted '*'
-db_set passwd/user-password-crypted ${user_crypted}
-db_set passwd/user-fullname "$USERFULLNAME"
-db_set passwd/username "$USERNAME"
-db_set passwd/user-uid 999
-
-chroot /root /usr/bin/env -i HOME="/root" \
- TERM="${TERM}" PATH="/usr/sbin:/usr/bin:/sbin:/bin" \
- /usr/lib/user-setup/user-setup-apply 2>&1 \
- | grep -v "Shadow passwords are now on"
-
-# Clear out debconf database again to avoid confusing ubiquity later.
-db_set passwd/make-user
-db_set passwd/root-password-crypted
-db_set passwd/user-password-crypted
-db_set passwd/user-fullname
-db_set passwd/username
-db_set passwd/user-uid
-
-if ! grep -qs "${USERNAME}" /root/etc/passwd
-then
- echo "The default user (${USERNAME}) is not present,"
- first_user=$(grep '^[^:]*:[^:]*:[12]\?[0-9][0-9][0-9][0-9]:' /root/etc/passwd | head -1 | cut -f1 -d ':')
- if [ -n "${first_user}" ];
- then
- echo "setting default user to: ${first_user}."
- USERNAME="${first_user}"
- really_export USERNAME
- else
- echo "no other valid users found, disabling autologin."
- NOAUTOLOGIN="Yes"
- NOXAUTOLOGIN="Yes"
- USERNAME=""
- really_export NOAUTOLOGIN
- really_export NOXAUTOLOGIN
- really_export USERNAME
- log_end_msg
- exit 0
- fi
-fi
-
-if [ -z "${NOSUDO}" ]
-then
- if ! grep -q "${USERNAME}" /root/etc/sudoers
- then
- echo "${USERNAME} ALL=(ALL) NOPASSWD: ALL" >> /root/etc/sudoers
-
- chroot /root sudo -u "${USERNAME}" sh -c "echo 'SU_TO_ROOT_SU=sudo' >> /home/${USERNAME}/.su-to-rootrc"
-
- if [ -x /root/usr/bin/gconftool-2 ]
- then
- chroot /root sudo -u "${USERNAME}" gconftool-2 -s -t bool /apps/gksu/sudo-mode true
- chroot /root sudo -u "${USERNAME}" gconftool-2 -s -t bool /apps/gksu/display-no-pass-info false
- fi
-
-chroot /root sudo -u "${USERNAME}" sh -c "umask 0077 && mkdir -p /home/${USERNAME}/.kde/share/config && cat > /home/${USERNAME}/.kde/share/config/kdesurc" << EOF
-[super-user-command]
-super-user-command=sudo
-EOF
-
- if [ -f /root/usr/share/apps/konsole/sumc.desktop ]
- then
- chroot /root sudo -u "${USERNAME}" sh -c "umask 0077 && mkdir -p /home/${USERNAME}/.kde/share/apps/konsole && sed -e's/Exec=su.*$/Exec=sudo mc -c/' /usr/share/apps/konsole/sumc.desktop > /home/${USERNAME}/.kde/share/apps/konsole/sumc.desktop"
- fi
-
- if [ -f /root/usr/share/apps/konsole/su.desktop ]
- then
- chroot /root sudo -u "${USERNAME}" sh -c "umask 0077 && mkdir -p /home/${USERNAME}/.kde/share/apps/konsole && sed -e's/Exec=su.*$/Exec=sudo -i/' /usr/share/apps/konsole/su.desktop > /home/${USERNAME}/.kde/share/apps/konsole/su.desktop"
- fi
- fi
-fi
-
-if [ -L /root/home/${USERNAME}/Examples ]
-then
- chroot /root install -o ${USERNAME} -g ${USERNAME} -d /home/${USERNAME}/Desktop/
- mv /root/home/${USERNAME}/Examples /root/home/${USERNAME}/Desktop/
-fi
-
-if [ -f /root/home/$USERNAME/examples.desktop ]; then
- chroot /root install -o $USERNAME -g $USERNAME -d /home/$USERNAME/Desktop/
- mv /root/home/$USERNAME/examples.desktop /root/home/$USERNAME/Desktop/
-fi
-
-if [ -e /root/usr/share/applications/live-installer-launcher.desktop ]
-then
- chroot /root install -D -o ${USERNAME} -g ${USERNAME} /usr/share/applications/live-installer-launcher.desktop /home/${USERNAME}/Desktop/live-installer-launcher.desktop
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/12fstab b/scripts/live-bottom/12fstab
index cd78edf..31e1e72 100755
--- a/scripts/live-bottom/12fstab
+++ b/scripts/live-bottom/12fstab
@@ -19,7 +19,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
. /scripts/live-functions
@@ -30,7 +30,7 @@ fi
log_begin_msg "Configuring fstab"
-# live-initramfs script
+# live-boot script
# Create a fake fstab only if it doesn't exist or if its the debootstrap template
if [ ! -f "${FSTAB}" ] || grep -qs 'UNCONFIGURED FSTAB FOR BASE SYSTEM' "${FSTAB}"
diff --git a/scripts/live-bottom/14locales b/scripts/live-bottom/14locales
index 022a605..e53e487 100755
--- a/scripts/live-bottom/14locales
+++ b/scripts/live-bottom/14locales
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOLOCALES}" ]
then
@@ -32,7 +32,7 @@ log_begin_msg "Setting up locales"
# Cosmetic line wrapping for output of local-gen
echo
-# live-initramfs script
+# live-boot script
if [ -e /root/etc/default/locale ]
then
diff --git a/scripts/live-bottom/15autologin b/scripts/live-bottom/15autologin
deleted file mode 100755
index 12c937d..0000000
--- a/scripts/live-bottom/15autologin
+++ /dev/null
@@ -1,114 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /live.vars
-
-if [ -n "${NOXAUTOLOGIN}" ] || [ -z "${USERNAME}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Setting up automatic login"
-
-# live-initramfs script
-
-# chroot needed to handle symlinks correctly
-if chroot /root [ -f /etc/gdm/gdm-cdd.conf ]
-then
- GDMCONF=/etc/gdm/gdm-cdd.conf
-else
- GDMCONF=/etc/gdm/gdm.conf
-fi
-
-# chroot needed to handle symlinks correctly
-if chroot /root [ -f ${GDMCONF} ]
-then
- # true hack ! -- nohar
- chroot /root cp /usr/share/gdm/defaults.conf /etc/gdm/gdm.conf
-
- # Configure GDM autologin
- chroot /root \
- sed -i -e "s/^AutomaticLoginEnable=.*\$/AutomaticLoginEnable=true/" \
- -e "s/^AutomaticLogin=.*\$/AutomaticLogin=${USERNAME}/" \
- -e "s/^TimedLoginEnable=.*\$/TimedLoginEnable=true/" \
- -e "s/^TimedLogin=.*\$/TimedLogin=${USERNAME}/" \
- -e "s/^TimedLoginDelay=.*\$/TimedLoginDelay=10/" \
- ${GDMCONF}
-elif [ -d /root/etc/gdm3 ]
-then
- GDMCustomFile=/root/etc/gdm3/custom.conf
- AutologinParameters="AutomaticLoginEnable=true\n\
-AutomaticLogin=$USERNAME\n\
-TimedLoginEnable=true\n\
-TimedLogin=$USERNAME\n\
-TimedLoginDelay=10"
-
- # Prevent from updating if parameters already present (persistent usb
- # key)
- if ! $(grep -qs '\[daemon\]' $GDMCustomFile)
- then
- echo '[daemon]' >> $GDMCustomFile
- fi
-
- sed -i "s/\[daemon\]/\[daemon\]\n$AutologinParameters/" $GDMCustomFile
-fi
-
-if [ -d /root/etc/default/kdm.d/ ]
-then
- if ! grep -qs "^AUTOLOGIN" /root/etc/default/kdm.d/live-autologin
- then
-
-cat >> /root/etc/default/kdm.d/live-autologin << EOF
-AUTOLOGINUSER=${USERNAME}
-AUTOLOGINAGAIN=true
-AUTOLOGINDELAY=0
-EOF
-
- fi
-
-elif [ -f /root/etc/kde3/kdm/kdmrc ]
-then
- # Configure KDM autologin
- sed -i -r -e "s/^#?AutoLoginEnable=.*\$/AutoLoginEnable=true/" \
- -e "s/^#?AutoLoginUser=.*\$/AutoLoginUser=${USERNAME}/" \
- -e "s/^#?AutoReLogin=.*\$/AutoReLogin=true/" \
- /root/etc/kde3/kdm/kdmrc
-elif [ -f /root/etc/kde4/kdm/kdmrc ]
-then
- # Configure KDM-KDE4 autologin
- sed -i -r -e "s/^#?AutoLoginEnable=.*\$/AutoLoginEnable=true/" \
- -e "s/^#?AutoLoginUser=.*\$/AutoLoginUser=$USERNAME/" \
- -e "s/^#?AutoReLogin=.*\$/AutoReLogin=true/" \
- /root/etc/kde4/kdm/kdmrc
-fi
-
-if [ -f /root/etc/lxdm/lxdm.conf ]
-then
- # Configure LXDM autologin
- sed -i -r -e "s/^# autologin=dgod/autologin=$USERNAME/" \
- -e "s/^# session/session/" \
- /root/etc/lxdm/lxdm.conf
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/16umountfs b/scripts/live-bottom/16umountfs
index 64ad99d..055c3f6 100755
--- a/scripts/live-bottom/16umountfs
+++ b/scripts/live-bottom/16umountfs
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
. /live.vars
@@ -26,7 +26,7 @@ esac
log_begin_msg "Disabling umountfs for live specific filesystems"
-# live-initramfs script
+# live-boot script
if [ -e /root/etc/init.d/umountfs ]
then
diff --git a/scripts/live-bottom/19keyboard b/scripts/live-bottom/19keyboard
index f903f2b..5a262fa 100755
--- a/scripts/live-bottom/19keyboard
+++ b/scripts/live-bottom/19keyboard
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOCONSOLEKEYBOARD}" ]
then
@@ -29,7 +29,7 @@ fi
log_begin_msg "Setting up console keyboard"
-# live-initramfs script
+# live-boot script
kbd=
cslayout=
diff --git a/scripts/live-bottom/20xconfig b/scripts/live-bottom/20xconfig
index e2839b2..abd9661 100755
--- a/scripts/live-bottom/20xconfig
+++ b/scripts/live-bottom/20xconfig
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOXAUTOCONFIG}" ]
then
@@ -27,7 +27,7 @@ fi
. /scripts/live-functions
-# live-initramfs script
+# live-boot script
if [ -n "${TEXTONLY}" ]
then
@@ -83,7 +83,7 @@ then
setlayout="set xserver-xorg/config/inputdevice/keyboard/layout ${KLAYOUT}"
fi
-chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << EOF
+chroot /root debconf-communicate -fnoninteractive live-boot > /dev/null << EOF
${setlayout}
${setvariant}
${setmodel}
diff --git a/scripts/live-bottom/21xdriver b/scripts/live-bottom/21xdriver
index e86c310..92bbd4f 100755
--- a/scripts/live-bottom/21xdriver
+++ b/scripts/live-bottom/21xdriver
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOXAUTOCONFIG}" ] || [ ! -x /root/usr/bin/X ] || [ -z "${XDRIVER}" ]
then
@@ -29,7 +29,7 @@ fi
log_begin_msg "Configuring X video driver"
-# live-initramfs script
+# live-boot script
. /live.vars
@@ -40,7 +40,7 @@ mount -o bind /dev /root/dev
if [ "${XDRIVER}" != "dexconf" ]
then
-chroot /root debconf-communicate -fnoninteractive live-initramfs > /dev/null << EOF
+chroot /root debconf-communicate -fnoninteractive live-boot > /dev/null << EOF
set xserver-xorg/autodetect_video_card false
set xserver-xorg/config/device/driver ${XDRIVER}
EOF
diff --git a/scripts/live-bottom/21xvidemode b/scripts/live-bottom/21xvidemode
index 3fb9190..ac28fad 100755
--- a/scripts/live-bottom/21xvidemode
+++ b/scripts/live-bottom/21xvidemode
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOXAUTOCONFIG}" ]
then
@@ -36,7 +36,7 @@ fi
log_begin_msg "Configuring X video modes"
-# live-initramfs script
+# live-boot script
. /live.vars
diff --git a/scripts/live-bottom/22gnome_panel_data b/scripts/live-bottom/22gnome_panel_data
deleted file mode 100755
index 09449e2..0000000
--- a/scripts/live-bottom/22gnome_panel_data
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ ! -e /root/var/lib/dpkg/info/gnome-panel-data.list ] || [ -n "${NOGNOMEPANEL}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Configuring gnome-panel-data"
-
-# live-initramfs script
-
-if [ -n "${USERNAME}" ]
-then
- chroot /root sudo -u "${USERNAME}" gconftool-2 -s -t bool /apps/panel/global/disable_lock_screen true
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/22screensaver b/scripts/live-bottom/22screensaver
deleted file mode 100755
index 584d234..0000000
--- a/scripts/live-bottom/22screensaver
+++ /dev/null
@@ -1,43 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOXSCREENSAVER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Configuring screensaver"
-
-# live-initramfs script
-
-gnome_screensaver_version=$(chroot /root dpkg-query -W --showformat='${Version}' gnome-screensaver 2>/dev/null) || gnome_screensaver_version=""
-
-if [ -n "${gnome_screensaver_version}" ]
-then
- # Support legacy gconf value
- chroot /root sudo -u "${USERNAME}" gconftool-2 -t bool -s /apps/gnome-screensaver/lock false
- chroot /root sudo -u "${USERNAME}" gconftool-2 -t bool -s /apps/gnome-screensaver/lock_enabled false
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/22serialtty b/scripts/live-bottom/22serialtty
index a8008eb..ee9ddb1 100755
--- a/scripts/live-bottom/22serialtty
+++ b/scripts/live-bottom/22serialtty
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
# this bottom script currently only works with upstart
if [ ! -d /root/etc/init ]
@@ -28,7 +28,7 @@ fi
. /scripts/live-functions
-# live-initramfs script
+# live-boot script
for ARGUMENT in $(cat /proc/cmdline)
do
diff --git a/scripts/live-bottom/22sslcert b/scripts/live-bottom/22sslcert
deleted file mode 100755
index d54dc29..0000000
--- a/scripts/live-bottom/22sslcert
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-load_confmodule
-
-log_begin_msg "Regenerating SSL certificate..."
-
-# live-initramfs script
-
-if [ -x /root/usr/sbin/make-ssl-cert ]
-then
- chroot /root /usr/sbin/make-ssl-cert generate-default-snakeoil --force-overwrite
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/23etc_modules b/scripts/live-bottom/23etc_modules
deleted file mode 100755
index 2240a1b..0000000
--- a/scripts/live-bottom/23etc_modules
+++ /dev/null
@@ -1,36 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Preconfiguring /etc/modules"
-
-# live-initramfs script
-
-# load the right modules
-case "${DPKG_ARCH}" in
- powerpc|ppc64)
- echo snd_powermac >> /root/etc/modules
- ;;
-esac
-
-log_end_msg
diff --git a/scripts/live-bottom/23networking b/scripts/live-bottom/23networking
index 4ebb944..d73f63b 100755
--- a/scripts/live-bottom/23networking
+++ b/scripts/live-bottom/23networking
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NONETWORKING}" ]
then
@@ -29,7 +29,7 @@ fi
log_begin_msg "Preconfiguring networking"
-# live-initramfs script
+# live-boot script
IFFILE="/root/etc/network/interfaces"
@@ -119,7 +119,7 @@ EOF
cat > /root/etc/resolv.conf << EOF
# /etc/resolv.conf
-# Autogenerated by live-initramfs
+# Autogenerated by live-boot
search ${rc_search}
domain ${rc_search}
${rc_server0}
diff --git a/scripts/live-bottom/24preseed b/scripts/live-bottom/24preseed
index 1f5c513..85c6494 100755
--- a/scripts/live-bottom/24preseed
+++ b/scripts/live-bottom/24preseed
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOPRESEED}" ]
then
@@ -26,22 +26,21 @@ then
fi
. /scripts/live-functions
-load_confmodule
log_begin_msg "Loading preseed file"
-# live-initramfs script
+# live-boot script
if [ -e /preseed.cfg ]
then
- live-set-selections /preseed.cfg
+ chroot /root debconf-set-selections < /preseed.cfg
fi
if [ -n "${LOCATIONS}" ]
then
for item in ${LOCATIONS}
do
- live-set-selections "/root$item"
+ chroot /root debconf-set-selections < "/root${item}"
done
fi
@@ -56,20 +55,14 @@ then
done
fi
-if db_get preseed/early_command && [ "$RET" ]
+reply="$(echo "GET preseed/early_command" | chroot /root debconf-communicate -fnoninteractive live-boot)"
+
+if [ "${reply#0 }" != "${reply}" ]
then
- EARLY="$RET"
- if db_get preseed/allow-network && [ "$RET" = true ]; then
- start_network
- fi
-
- DEBIAN_HAS_FRONTEND= DEBCONF_REDIR= \
- DEBIAN_FRONTEND=noninteractive \
- sh -c "$EARLY"
+ reply="${reply#0 }"
+ sh -c "${reply}"
fi
-stop_network
-
# Clear out debconf database backup files to save memory.
rm -f /root/var/cache/debconf/*.dat-old
diff --git a/scripts/live-bottom/25configure_init b/scripts/live-bottom/25configure_init
index c06617f..a84eb75 100755
--- a/scripts/live-bottom/25configure_init
+++ b/scripts/live-bottom/25configure_init
@@ -18,13 +18,13 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
. /scripts/live-functions
log_begin_msg "Setting up init"
-# live-initramfs script
+# live-boot script
# Arrange for shells on virtual consoles, rather than login prompts
diff --git a/scripts/live-bottom/30accessibility b/scripts/live-bottom/30accessibility
index 75bfae4..ef83c72 100755
--- a/scripts/live-bottom/30accessibility
+++ b/scripts/live-bottom/30accessibility
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOACCESSIBILITY}" ]
then
@@ -35,7 +35,7 @@ fi
log_begin_msg "Configuring accessibility options"
-# live-initramfs script
+# live-boot script
gconf_version=$(chroot /root /usr/bin/dpkg-query -W --showformat='${Version}' gconf2 2>/dev/null) || gconf_version=""
diff --git a/scripts/live-bottom/31disable_update_notifier b/scripts/live-bottom/31disable_update_notifier
deleted file mode 100755
index 0edf189..0000000
--- a/scripts/live-bottom/31disable_update_notifier
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOUPDATENOTIFIER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Disabling update-notifier"
-
-# live-initramfs script
-
-# For GNOME, we divert away apt-check to avoid a regular 'apt-get update'
-# equivalent in the live session. We want to run update-notifier for crash
-# report handling.
-chroot /root dpkg-divert --add --rename --quiet \
- /usr/lib/update-notifier/apt-check
-
-if [ -e /root/usr/lib/update-notifier/apt-check ]
-then
- ln -sf /bin/true /root/usr/lib/update-notifier/apt-check
-fi
-
-# For KDE, adept_notifier's only useful function at the moment is an
-# 'apt-get update' equivalent, so we disable it entirely.
-rm -f /root/usr/share/autostart/adept_notifier_auto.desktop
-
-log_end_msg
diff --git a/scripts/live-bottom/32disable_hibernation b/scripts/live-bottom/32disable_hibernation
deleted file mode 100755
index f4960e6..0000000
--- a/scripts/live-bottom/32disable_hibernation
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOPOWERMANAGEMENT}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Configuring power management"
-
-# live-initramfs script
-
-gpm_version=$(chroot /root /usr/bin/dpkg-query -W --showformat='${Version}' gnome-power-manager 2>/dev/null) || panel_version=""
-
-if [ -n "${gpm_version}" ] && [ -n "${USERNAME}" ]
-then
- #live-reconfigure /root gnome-power-manager
- # Gnome < 2.20
- chroot /root sudo -u "${USERNAME}" gconftool-2 -s -t bool /apps/gnome-power-manager/can_hibernate false
- # Gnome >= 2.20
- chroot /root sudo -u "${USERNAME}" gconftool-2 -s -t bool /apps/gnome-power-manager/general/can_hibernate false
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/33enable_apport_crashes b/scripts/live-bottom/33enable_apport_crashes
deleted file mode 100755
index 47e650d..0000000
--- a/scripts/live-bottom/33enable_apport_crashes
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOPROGRAMCRASHES}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Enabling detection of crashes"
-
-# live-initramfs script
-
-if [ -e /root/etc/default/apport ]
-then
- sed -i 's/enabled=0/enabled=1/' /root/etc/default/apport
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/34disable_kaboom b/scripts/live-bottom/34disable_kaboom
deleted file mode 100755
index 2bb474c..0000000
--- a/scripts/live-bottom/34disable_kaboom
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Disabling kaboom"
-
-# live-initramfs script
-
-if [ -e /root/etc/kde4 ]
-then
- mkdir -p /root/home/${USERNAME}/.local
- touch /root/home/${USERNAME}/.local/kaboom
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/34disable_kde_services b/scripts/live-bottom/34disable_kde_services
deleted file mode 100755
index 41f881c..0000000
--- a/scripts/live-bottom/34disable_kde_services
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Disabling unnecessary KDE services..."
-
-# live-initramfs script
-
-rm -f /root/usr/share/autostart/kab2kabc.desktop
-rm -f /root/usr/share/autostart/kabcdistlistupdater.desktop
-rm -f /root/usr/share/autostart/korgac.desktop
-rm -f /root/usr/share/autostart/printer-applet.desktop
-rm -f /root/usr/share/autostart/nepomukserver.desktop
-rm -f /root/usr/share/kde4/services/kwalletd.desktop
-rm -f /root/usr/share/kde4/services/kded/kpackagekitd.desktop
-rm -f /root/usr/share/kde4/services/kded/freespacenotifier.desktop
-rm -f /root/usr/share/kde4/services/plasma-runner-contacts.desktop # starts akonadi
-rm -f /root/usr/share/kde4/services/kded/notificationhelper.desktop
-
-log_end_msg
diff --git a/scripts/live-bottom/34disable_kpersonalizer b/scripts/live-bottom/34disable_kpersonalizer
deleted file mode 100755
index 8f6709b..0000000
--- a/scripts/live-bottom/34disable_kpersonalizer
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOKPERSONALIZER}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Disabling kpersonalizer"
-
-# live-initramfs script
-
-if [ -e /root/etc/kde3 ]
-then
- if chroot /root /usr/bin/which kpersonalizer >/dev/null
- then
- # Disable first-login wizard for KDE
- if [ ! -f /root/etc/kde3/kpersonalizerrc ]
- then
-
-cat > /root/etc/kde3/kpersonalizerrc << EOF
-[General]
-FirstLogin=false
-EOF
-
- else
- echo "I'm not smart enough to disable kpersonalizer startup" >&2
- echo "Because kpersonalizerrc already exists" >&2
- fi
- fi
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/35fix_language_selector b/scripts/live-bottom/35fix_language_selector
deleted file mode 100755
index 8452d12..0000000
--- a/scripts/live-bottom/35fix_language_selector
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOLANGUAGESELECTOR}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Fixing language selector"
-
-# live-initramfs script
-
-if [ -e /root/usr/share/applications/language-selector.desktop ]
-then
- sed -i '/^Exec/ s|/usr/bin/gnome-language-selector|& -n|' /root/usr/share/applications/language-selector.desktop
-fi
-
-if [ -x /root/usr/bin/fontconfig-voodoo ]
-then
- chroot /root fontconfig-voodoo --auto --quiet || true
-fi
-
-log_end_msg
diff --git a/scripts/live-bottom/36disable_trackerd b/scripts/live-bottom/36disable_trackerd
deleted file mode 100755
index 667131d..0000000
--- a/scripts/live-bottom/36disable_trackerd
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -n "${NOTIMEZONE}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Disabling trackerd"
-
-# live-initramfs script
-
-rm -f /root/etc/xdg/autostart/tracker-applet.desktop \
- /root/etc/xdg/autostart/trackerd.desktop \
- /root/usr/share/autostart/trackerd.desktop
-
-log_end_msg
diff --git a/scripts/live-bottom/41apt_cdrom b/scripts/live-bottom/41apt_cdrom
index eb7fbd8..1a36e7f 100755
--- a/scripts/live-bottom/41apt_cdrom
+++ b/scripts/live-bottom/41apt_cdrom
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs header
+# live-boot header
if [ -n "${NOAPTCDROM}" ]
then
@@ -29,7 +29,7 @@ fi
log_begin_msg "Adding APT-CDROM source"
-# live-initramfs script
+# live-boot script
if [ -d /root/cdrom ]
then
diff --git a/scripts/live-bottom/43disable_updateinitramfs b/scripts/live-bottom/43disable_updateinitramfs
deleted file mode 100755
index 44e2d1f..0000000
--- a/scripts/live-bottom/43disable_updateinitramfs
+++ /dev/null
@@ -1,73 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Possibly disabling update-initramfs (useless on a live CD)..."
-
-# live-initramfs script
-
-chroot /root dpkg-divert --add --rename --quiet \
- /usr/sbin/update-initramfs
-
-# Running off a USB disk or other writable media.
-if [ -w /root/cdrom ] && \
- # rw is guaranteed to be first.
- grep -q ' /root/cdrom rw[, ]' /proc/self/mountinfo
-then
-
-cat > /root/usr/sbin/update-initramfs << 'EOF'
-#!/bin/sh
-
-set -e
-
-update-initramfs.distrib "$@"
-
-if [ -e /cdrom/live/initrd.lz ]
-then
- zcat /initrd.img | lzma -9c >/cdrom/live/initrd.lz.new
- mv /cdrom/live/initrd.lz.new /cdrom/live/initrd.lz
-else
- cp /initrd.img /cdrom/live/initrd.gz.new
- mv /cdrom/live/initrd.gz.new /cdrom/live/initrd.gz
-fi
-
-cp /vmlinuz /cdrom/live/vmlinuz.new
-mv /cdrom/live/vmlinuz.new /cdrom/live/vmlinuz
-
-exit 0
-EOF
-
-else
-
-cat > /root/usr/sbin/update-initramfs << EOF
-#!/bin/sh
-
-echo "update-initramfs is disabled since running on read-only media"
-exit 0
-EOF
-
-fi
-
-chmod 0755 /root/usr/sbin/update-initramfs
-
-log_end_msg
diff --git a/scripts/live-bottom/44pk_allow b/scripts/live-bottom/44pk_allow
deleted file mode 100755
index a211880..0000000
--- a/scripts/live-bottom/44pk_allow
+++ /dev/null
@@ -1,71 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-. /scripts/live-functions
-
-log_begin_msg "Grant administrative PolicyKit pivilieges to default user"
-
-# live-initramfs script
-
-# configure PolicyKit in live session
-mkdir -p /root/etc/PolicyKit
-cat << EOF > /root/etc/PolicyKit/PolicyKit.conf
-<?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- -->
-
-<!DOCTYPE pkconfig PUBLIC "-//freedesktop//DTD PolicyKit Configuration 1.0//EN"
-"http://hal.freedesktop.org/releases/PolicyKit/1.0/config.dtd">
-
-<!-- See the manual page PolicyKit.conf(5) for file format -->
-
-<config version="0.1">
- <match user="root">
- <return result="yes"/>
- </match>
-EOF
-
-if [ -n "${USERNAME}" ]
-then
- cat << EOF >> /root/etc/PolicyKit/PolicyKit.conf
- <!-- don't ask password for user in live session -->
- <match user="$USERNAME">
- <return result="yes"/>
- </match>
-EOF
-fi
-
-cat << EOF >> /root/etc/PolicyKit/PolicyKit.conf
- <define_admin_auth group="admin"/>
-</config>
-EOF
-
-mkdir -p /root/var/lib/polkit-1/localauthority/10-vendor.d
-cat << EOF > /root/var/lib/polkit-1/localauthority/10-vendor.d/10-live-cd.pkla
-# Policy to allow the livecd user to bypass policykit
-[Live CD user permissions]
-Identity=unix-user:$USERNAME
-Action=*
-ResultAny=no
-ResultInactive=no
-ResultActive=yes
-EOF
-
-log_end_msg
diff --git a/scripts/live-bottom/99hook b/scripts/live-bottom/99hook
deleted file mode 100755
index 8809800..0000000
--- a/scripts/live-bottom/99hook
+++ /dev/null
@@ -1,50 +0,0 @@
-#!/bin/sh
-
-#set -e
-
-# initramfs-tools header
-
-PREREQ=""
-
-prereqs()
-{
- echo "${PREREQ}"
-}
-
-case "${1}" in
- prereqs)
- prereqs
- exit 0
- ;;
-esac
-
-# live-initramfs header
-
-if [ -z "${HOOK}" ]
-then
- exit 0
-fi
-
-. /scripts/live-functions
-
-log_begin_msg "Executing custom hook script"
-
-# live-initramfs script
-
-cd /root
-
-if [ $(echo "${HOOK}" | grep file:\/\/) ]
-then
- LOCALFILE=$(echo ${HOOK} | sed "s/file\:\/\///")
- cp ${LOCALFILE} /root
-else
- chroot /root wget "${HOOK}"
-fi
-
-FILE="$(basename ${HOOK})"
-
-chmod 0755 "${FILE}"
-./"${FILE}"
-rm -f "${FILE}"
-
-log_end_msg
diff --git a/scripts/live-functions b/scripts/live-functions
index 9e138ec..b1d7503 100644
--- a/scripts/live-functions
+++ b/scripts/live-functions
@@ -39,7 +39,7 @@ lang2locale() {
langpart="${1%%_*}"
if [ "$1" != "C" ]; then
# Match the language code with 3rd field in languagelist
- line=$(grep -v "^#" /usr/share/live-initramfs/languagelist | cut -f1,3,6 -d\; | grep -v ';C$' | grep "^$langpart;")
+ line=$(grep -v "^#" /usr/share/live-boot/languagelist | cut -f1,3,6 -d\; | grep -v ';C$' | grep "^$langpart;")
if [ -n "$line" ]; then
if [ "$(echo "$line" | grep -c '')" -gt 1 ]; then
# More than one match; try matching the
@@ -96,7 +96,7 @@ panic() {
printf " ${DEB_3}\n"
printf " ${DEB_4} This Debian Live image failed to boot.\n\n"
- printf " Please file a bug against the 'live-initramfs' package or email the Debian\n"
+ printf " Please file a bug against the 'live-boot' package or email the Debian\n"
printf " Live mailing list at <debian-live@lists.debian.org>, making sure to note the\n"
printf " exact version, name and distribution of the image you were attempting to boot.\n\n"
@@ -105,9 +105,9 @@ panic() {
printf " extremely useful when diagnosing issues.\n\n"
if [ -n "${panic}" ]; then
- printf " live-initramfs will now restart your system. "
+ printf " live-boot will now restart your system. "
else
- printf " live-initramfs will now start a shell. "
+ printf " live-boot will now start a shell. "
fi
printf "The error message was:\n\n "
@@ -115,16 +115,3 @@ panic() {
. /scripts/functions
panic "$@"
}
-
-load_confmodule ()
-{
- # Only do this once
- if [ -z "$DEBCONF_REDIR" ]
- then
- exec <&4
- export DEBIAN_HAS_FRONTEND=1
- export DEBCONF_REDIR=1
- fi
-
- . /root/usr/share/debconf/confmodule
-}
diff --git a/scripts/live-helpers b/scripts/live-helpers
index d82efa5..314c33f 100644
--- a/scripts/live-helpers
+++ b/scripts/live-helpers
@@ -1,4 +1,4 @@
-# live-initramfs helper functions, used by live-initramfs on boot and by live-snapshot
+# live-boot helper functions, used by live-boot on boot and by live-snapshot
if [ ! -x "/bin/fstype" ]
then
diff --git a/scripts/live-premount/modules b/scripts/live-premount/modules
index 408e873..1af7a9e 100755
--- a/scripts/live-premount/modules
+++ b/scripts/live-premount/modules
@@ -18,9 +18,9 @@ case "${1}" in
;;
esac
-# live-initramfs script
+# live-boot script
-# The following modprobe entry is a workaround to live-initramfs not
+# The following modprobe entry is a workaround to live-boot not
# finding the root filesytem.
#
# See also:
diff --git a/scripts/live-premount/readonly b/scripts/live-premount/readonly
index 8bed733..71483bd 100755
--- a/scripts/live-premount/readonly
+++ b/scripts/live-premount/readonly
@@ -18,7 +18,7 @@ case "${1}" in
;;
esac
-# live-initramfs script
+# live-boot script
# make sure all harddisk devices are read-only
# this is important for forensic investigations