X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=blobdiff_plain;f=chroot-script;h=3a8dca903f03e59efb51d1dce7919bf2f903c955;hp=bbc91f095bac7c743ac67066a1808d303396348f;hb=430c060be15f60f508428edbc03ea70d9bf04399;hpb=4f436b493216046d6e77eeb486a6e91d13ba887f diff --git a/chroot-script b/chroot-script index bbc91f0..3a8dca9 100755 --- a/chroot-script +++ b/chroot-script @@ -88,7 +88,7 @@ chrootmirror() { # add security.debian.org: case "$RELEASE" in - unstable|sid) ;; # no security pool available + unstable|sid|lenny) ;; # no security pool available *) echo "Adding security.debian.org to sources.list." echo "deb http://security.debian.org ${RELEASE}/updates $COMPONENTS" >> /etc/apt/sources.list @@ -223,7 +223,7 @@ upgrade_system() { if [ "$UPGRADE_SYSTEM" = "yes" ] ; then echo "Running update + upgrade" $APTUPDATE - $APTUPGRADE + DEBIAN_FRONTEND=$DEBIAN_FRONTEND $APTUPGRADE else echo "Not running update + upgrade as \$UPDATE_AND_UPGRADE is not set to 'yes'." fi @@ -311,6 +311,11 @@ get_kernel_version() { # install kernel packages {{{ kernel() { + if [ -n "$NOKERNEL" ] ; then + echo "Skipping installation of kernel packages as requested via --nokernel" + return 0 + fi + $APTUPDATE KVER=$(get_kernel_version) if [ -n "$KVER" ] ; then @@ -409,25 +414,6 @@ EOF } # }}} -# set up /etc/network/interfaces {{{ -interfaces() { - if ! [ -r /etc/network/interfaces ] || ! grep -q "auto lo" /etc/network/interfaces ; then - echo "Setting up /etc/network/interfaces" - cat >> /etc/network/interfaces << EOF - -# loopback device: -iface lo inet loopback -auto lo - -# eth0: -# iface eth0 inet dhcp -# auto eth0 - -EOF - fi -} -# }}} - # set default locales {{{ default_locales() { if [ -n "$DEFAULT_LOCALES" ] ; then @@ -437,7 +423,7 @@ default_locales() { return 0 fi - /usr/sbin/update-locale LANG="$DEFAULT_LOCALES" + /usr/sbin/update-locale LANGUAGE="$DEFAULT_LANGUAGE" LANG="$DEFAULT_LOCALES" fi } # }}} @@ -466,7 +452,7 @@ proc /proc proc defaults 0 0 # some other examples: # /dev/sda2 none swap sw,pri=0 0 0 # /dev/hda1 /Grml ext3 dev,suid,user,noauto 0 2 -# //1.2.3.4/pub /smb/pub smbfs defaults,user,noauto,uid=grml,gid=grml 0 0 +# //1.2.3.4/pub /smb/pub cifs user,noauto,uid=grml,gid=grml 0 0 # linux:/pub /beer nfs defaults 0 0 # tmpfs /tmp tmpfs size=300M 0 0 # /dev/sda5 none swap sw 0 0 @@ -621,7 +607,7 @@ trap signal_handler HUP INT QUIT TERM install_policy_rcd for i in chrootmirror grmlrepos backportrepos kernelimg_conf \ - kernel packages extrapackages reconfigure hosts interfaces \ + kernel packages extrapackages reconfigure hosts \ default_locales timezone fstab hostname initrd grub_install passwords \ custom_scripts upgrade_system remove_apt_cache services \ remove_chrootmirror; do