From 414ebf318f87cca1d036e3ef6674ade15876db55 Mon Sep 17 00:00:00 2001 From: Michael Aldridge Date: Sat, 12 Mar 2016 21:58:30 -0600 Subject: [PATCH] Add netboot generator script --- .gitignore | 1 + .../autoinstaller}/autoinstall.cfg | 0 .../autoinstaller}/install.sh | 0 .../autoinstaller}/module-setup.sh | 0 dracut/netmenu/module-setup.sh | 85 +++++ dracut/netmenu/netmenu.sh | 18 ++ dracut/{ => vmklive}/59-mtd.rules | 0 dracut/{ => vmklive}/61-mtd.rules | 0 dracut/{ => vmklive}/adduser.sh | 0 dracut/{ => vmklive}/copy-initramfs.sh | 0 .../display-manager-autologin.sh | 0 dracut/{ => vmklive}/locale.sh | 0 dracut/{ => vmklive}/module-setup.sh | 0 dracut/{ => vmklive}/mtd.sh | 0 dracut/{ => vmklive}/services.sh | 0 mklive.sh.in | 4 +- mknet.sh.in | 302 ++++++++++++++++++ pxelinux.cfg/pxelinux.cfg.in | 36 +++ 18 files changed, 444 insertions(+), 2 deletions(-) rename {autoinstaller => dracut/autoinstaller}/autoinstall.cfg (100%) rename {autoinstaller => dracut/autoinstaller}/install.sh (100%) rename {autoinstaller => dracut/autoinstaller}/module-setup.sh (100%) create mode 100644 dracut/netmenu/module-setup.sh create mode 100755 dracut/netmenu/netmenu.sh rename dracut/{ => vmklive}/59-mtd.rules (100%) rename dracut/{ => vmklive}/61-mtd.rules (100%) rename dracut/{ => vmklive}/adduser.sh (100%) rename dracut/{ => vmklive}/copy-initramfs.sh (100%) rename dracut/{ => vmklive}/display-manager-autologin.sh (100%) rename dracut/{ => vmklive}/locale.sh (100%) rename dracut/{ => vmklive}/module-setup.sh (100%) rename dracut/{ => vmklive}/mtd.sh (100%) rename dracut/{ => vmklive}/services.sh (100%) create mode 100644 mknet.sh.in create mode 100644 pxelinux.cfg/pxelinux.cfg.in diff --git a/.gitignore b/.gitignore index fff3846..daa5a14 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ *.raw *.tar.gz xbps-cachedir* +!dracut/*/*.sh diff --git a/autoinstaller/autoinstall.cfg b/dracut/autoinstaller/autoinstall.cfg similarity index 100% rename from autoinstaller/autoinstall.cfg rename to dracut/autoinstaller/autoinstall.cfg diff --git a/autoinstaller/install.sh b/dracut/autoinstaller/install.sh similarity index 100% rename from autoinstaller/install.sh rename to dracut/autoinstaller/install.sh diff --git a/autoinstaller/module-setup.sh b/dracut/autoinstaller/module-setup.sh similarity index 100% rename from autoinstaller/module-setup.sh rename to dracut/autoinstaller/module-setup.sh diff --git a/dracut/netmenu/module-setup.sh b/dracut/netmenu/module-setup.sh new file mode 100644 index 0000000..7e5fc42 --- /dev/null +++ b/dracut/netmenu/module-setup.sh @@ -0,0 +1,85 @@ +#!/bin/bash +# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- +# ex: ts=8 sw=4 sts=4 et filetype=sh + +check() { + return 255 +} + +depends() { + return 0 +} + +install() { + inst /usr/bin/awk + inst /usr/bin/basename + inst /usr/bin/bash + inst /usr/bin/cat + inst /usr/bin/cfdisk + inst /usr/bin/chroot + inst /usr/bin/clear + inst /usr/bin/cut + inst /usr/bin/cp + inst /usr/bin/dhcpcd + inst /usr/bin/dialog + inst /usr/bin/echo + inst /usr/bin/env + inst /usr/bin/find + inst /usr/bin/find + inst /usr/bin/grep + inst /usr/bin/head + inst /usr/bin/id + inst /usr/bin/ln + inst /usr/bin/ls + inst /usr/bin/lsblk + inst /usr/bin/mke2fs + inst /usr/bin/mkfs.btrfs + inst /usr/bin/mkfs.f2fs + inst /usr/bin/mkfs.vfat + inst /usr/bin/mkfs.xfs + inst /usr/bin/mkswap + inst /usr/bin/mktemp + inst /usr/bin/mount + inst /usr/bin/reboot + inst /usr/bin/rm + inst /usr/bin/sed + inst /usr/bin/sort + inst /usr/bin/sync + inst /usr/bin/stdbuf + inst /usr/bin/sleep + inst /usr/bin/touch + inst /usr/bin/xargs + inst /usr/bin/xbps-install + inst /usr/bin/xbps-reconfigure + inst /usr/bin/xbps-remove + inst /usr/bin/xbps-uhelper + + inst /usr/libexec/dhcpcd-hooks/20-resolv.conf + inst /usr/libexec/dhcpcd-run-hooks + inst /usr/libexec/coreutils/libstdbuf.so + + inst_multiple /var/db/xbps/keys/* + inst_multiple /usr/share/xbps.d/* + inst_multiple /usr/share/zoneinfo/*/* + + inst_multiple /etc/ssl/certs/* + inst /etc/ssl/certs.pem + + inst /etc/default/libc-locales + inst /etc/group + + # We need to remove a choice here since the installer's initrd + # can't function as a local source. Strictly we shouldn't be + # doing this from dracut's installation function, but this is the + # last place that file really exists 'on disk' in the sense that + # we can modify it, so this change is applied here. + sed -i '/Packages from ISO image/d' "$moddir/installer.sh" + + # The system doesn't have a real init up so the reboot is going to + # be rough, we make it an option though if the end user wants to + # do this... + sed -i "s:shutdown -r now:sync && reboot -f:" "$moddir/installer.sh" + + inst "$moddir/installer.sh" /usr/bin/void-installer + inst_hook pre-mount 05 "$moddir/netmenu.sh" +} diff --git a/dracut/netmenu/netmenu.sh b/dracut/netmenu/netmenu.sh new file mode 100755 index 0000000..448a5e2 --- /dev/null +++ b/dracut/netmenu/netmenu.sh @@ -0,0 +1,18 @@ +#!/bin/sh + +dialog --colors --keep-tite --no-shadow --no-mouse \ + --backtitle "\Zb\Z7Void Linux installation -- http://www.voidlinux.eu/\Zn" \ + --cancel-label "Reboot" --aspect 20 \ + --menu "Select an Action:" 10 50 2 \ + "Install" "Run void-installer" \ + "Shell" "Run dash" \ + 2>/tmp/netmenu.action + +if ! $? ; then + reboot -f +fi + +case $(cat /tmp/netmenu.action) in + "Install") /usr/bin/void-installer ; exec sh ;; + "Shell") exec sh ;; +esac diff --git a/dracut/59-mtd.rules b/dracut/vmklive/59-mtd.rules similarity index 100% rename from dracut/59-mtd.rules rename to dracut/vmklive/59-mtd.rules diff --git a/dracut/61-mtd.rules b/dracut/vmklive/61-mtd.rules similarity index 100% rename from dracut/61-mtd.rules rename to dracut/vmklive/61-mtd.rules diff --git a/dracut/adduser.sh b/dracut/vmklive/adduser.sh similarity index 100% rename from dracut/adduser.sh rename to dracut/vmklive/adduser.sh diff --git a/dracut/copy-initramfs.sh b/dracut/vmklive/copy-initramfs.sh similarity index 100% rename from dracut/copy-initramfs.sh rename to dracut/vmklive/copy-initramfs.sh diff --git a/dracut/display-manager-autologin.sh b/dracut/vmklive/display-manager-autologin.sh similarity index 100% rename from dracut/display-manager-autologin.sh rename to dracut/vmklive/display-manager-autologin.sh diff --git a/dracut/locale.sh b/dracut/vmklive/locale.sh similarity index 100% rename from dracut/locale.sh rename to dracut/vmklive/locale.sh diff --git a/dracut/module-setup.sh b/dracut/vmklive/module-setup.sh similarity index 100% rename from dracut/module-setup.sh rename to dracut/vmklive/module-setup.sh diff --git a/dracut/mtd.sh b/dracut/vmklive/mtd.sh similarity index 100% rename from dracut/mtd.sh rename to dracut/vmklive/mtd.sh diff --git a/dracut/services.sh b/dracut/vmklive/services.sh similarity index 100% rename from dracut/services.sh rename to dracut/vmklive/services.sh diff --git a/mklive.sh.in b/mklive.sh.in index 91b3496..cf2aff0 100644 --- a/mklive.sh.in +++ b/mklive.sh.in @@ -100,12 +100,12 @@ copy_void_conf() { copy_dracut_files() { mkdir -p $1/usr/lib/dracut/modules.d/01vmklive - cp dracut/* $1/usr/lib/dracut/modules.d/01vmklive/ + cp dracut/vmklive/* $1/usr/lib/dracut/modules.d/01vmklive/ } copy_autoinstaller_files() { mkdir -p $1/usr/lib/dracut/modules.d/01autoinstaller - cp autoinstaller/* $1/usr/lib/dracut/modules.d/01autoinstaller/ + cp dracut/autoinstaller/* $1/usr/lib/dracut/modules.d/01autoinstaller/ } install_prereqs() { diff --git a/mknet.sh.in b/mknet.sh.in new file mode 100644 index 0000000..f72a939 --- /dev/null +++ b/mknet.sh.in @@ -0,0 +1,302 @@ +#!/bin/sh +# +# vim: set ts=4 sw=4 et: +# +#- +# Copyright (c) 2009-2015 Juan Romero Pardines. +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR +# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, +# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#- +trap "error_out $LINENO $?" INT TERM 0 + +readonly REQUIRED_PKGS="base-files libgcc dash coreutils sed tar gawk syslinux squashfs-tools" +readonly INITRAMFS_PKGS="binutils xz device-mapper dracut-network dhclient dialog" +readonly PROGNAME=$(basename $0) + +info_msg() { + printf "\033[1m$@\n\033[m" +} +die() { + info_msg "ERROR: $@" + error_out 1 +} +print_step() { + CURRENT_STEP=$((CURRENT_STEP+1)) + info_msg "[${CURRENT_STEP}/${STEP_COUNT}] $@" +} +mount_pseudofs() { + for f in sys dev proc; do + mkdir -p $ROOTFS/$f + mount --bind /$f $ROOTFS/$f + done +} +umount_pseudofs() { + umount -f $ROOTFS/sys >/dev/null 2>&1 + umount -f $ROOTFS/dev >/dev/null 2>&1 + umount -f $ROOTFS/proc >/dev/null 2>&1 +} +error_out() { + umount_pseudofs + [ -d "$BUILDDIR" -a -z "$KEEP_BUILDDIR" ] && rm -rf "$BUILDDIR" + exit ${1:=0} +} + +usage() { + cat <<_EOF +Usage: $PROGNAME [options] + +Options: + -a Set XBPS_ARCH (do not use it unless you know what it is) + -b Set an alternative base-system package (defaults to base-system). + -r Use this XBPS repository (may be specified multiple times). + -c Use this XBPS cache directory (/var/cache/xbps if unset). + -k Default keymap to use (us if unset) + -l Default locale to use (en_US.UTF-8 if unset). + -i Compression type for the initramfs image (lz4 if unset). + -o Output file name for the netboot tarball (auto if unset). + + -C "cmdline args" Add additional kernel command line arguments. + -T "title" Modify the bootloader title. + -K Do not remove builddir. + +The $PROGNAME script generates a network-bootable tarball of Void Linux +This *.tar.gz contains only the autoinstaller. +_EOF + exit 1 +} + +copy_void_keys() { + mkdir -p "$1"/var/db/xbps/keys + cp keys/*.plist "$1"/var/db/xbps/keys +} + +copy_void_conf() { + install -Dm644 data/void-vpkgs.conf "$1"/usr/share/xbps.d/void-virtualpkgs.conf +} + +copy_netmenu_files() { + mkdir -p $1/usr/lib/dracut/modules.d/05netmenu + cp dracut/netmenu/* $1/usr/lib/dracut/modules.d/05netmenu/ + + # The netmenu can directly launch the manual installer from the initrd + cp installer.sh $1/usr/lib/dracut/modules.d/05netmenu/ +} + +copy_autoinstaller_files() { + mkdir -p $1/usr/lib/dracut/modules.d/01autoinstaller + cp dracut/autoinstaller/* $1/usr/lib/dracut/modules.d/01autoinstaller/ +} + +install_prereqs() { + copy_void_conf $VOIDHOSTDIR + XBPS_ARCH=$ARCH $XBPS_INSTALL_CMD -r $VOIDHOSTDIR $XBPS_REPOSITORY \ + $XBPS_HOST_CACHEDIR -y ${REQUIRED_PKGS} + [ $? -ne 0 ] && die "Failed to install required software, exiting..." +} + +install_packages() { + copy_void_conf $ROOTFS + + XBPS_ARCH=$BASE_ARCH ${XBPS_INSTALL_CMD} -r $ROOTFS \ + $XBPS_REPOSITORY $XBPS_CACHEDIR -yn ${PACKAGE_LIST} ${INITRAMFS_PKGS} + [ $? -ne 0 ] && die "Missing required binary packages, exiting..." + + mount_pseudofs + + LANG=C XBPS_ARCH=$BASE_ARCH ${XBPS_INSTALL_CMD} -U -r $ROOTFS \ + $XBPS_REPOSITORY $XBPS_CACHEDIR -y ${PACKAGE_LIST} ${INITRAMFS_PKGS} + [ $? -ne 0 ] && die "Failed to install $PACKAGE_LIST" + + xbps-reconfigure -r $ROOTFS -f base-files >/dev/null 2>&1 + chroot $ROOTFS env -i xbps-reconfigure -f base-files + + # Enable choosen UTF-8 locale and generate it into the target rootfs. + if [ -f $ROOTFS/etc/default/libc-locales ]; then + sed -e "s/\#\(${LOCALE}.*\)/\1/g" -i $ROOTFS/etc/default/libc-locales + fi + chroot $ROOTFS env -i xbps-reconfigure -a + + if [ -x installer.sh ]; then + install -Dm755 installer.sh $ROOTFS/usr/sbin/void-installer + else + install -Dm755 /usr/sbin/void-installer $ROOTFS/usr/sbin/void-installer + fi + # Cleanup and remove useless stuff. + rm -rf $ROOTFS/var/cache/* $ROOTFS/run/* $ROOTFS/var/run/* +} + +copy_include_directory() { + find $INCLUDE_DIRECTORY -mindepth 1 -maxdepth 1 -exec cp -rfpPv {} $ROOTFS/ \; +} + +generate_initramfs() { + local _args + + copy_netmenu_files $ROOTFS + copy_autoinstaller_files $ROOTFS + if [ "$BASE_SYSTEM_PKG" = "base-system-systemd" ]; then + _args="--add systemd" + else + _args="--omit systemd" + fi + chroot $ROOTFS env -i /usr/bin/dracut -N --${INITRAMFS_COMPRESSION} \ + --add-drivers "ahci" --force-add "autoinstaller netmenu" ${_args} "/boot/initrd" $KERNELVERSION + [ $? -ne 0 ] && die "Failed to generate the initramfs" + + mv $ROOTFS/boot/initrd $BOOT_DIR + cp $ROOTFS/boot/vmlinuz-$KERNELVERSION $BOOT_DIR/vmlinuz + chmod 0644 $BOOT_DIR/initrd +} + +generate_pxelinux_boot() { + cp -f $SYSLINUX_DATADIR/pxelinux.0 "$BOOT_DIR" + cp -f $SYSLINUX_DATADIR/ldlinux.c32 "$BOOT_DIR" + cp -f $SYSLINUX_DATADIR/libcom32.c32 "$BOOT_DIR" + cp -f $SYSLINUX_DATADIR/vesamenu.c32 "$BOOT_DIR" + cp -f $SYSLINUX_DATADIR/libutil.c32 "$BOOT_DIR" + cp -f $SYSLINUX_DATADIR/chain.c32 "$BOOT_DIR" + cp -f pxelinux.cfg/pxelinux.cfg.in "$PXELINUX_DIR"/default + cp -f ${SPLASH_IMAGE} "$BOOT_DIR" + + sed -i -e "s|@@SPLASHIMAGE@@|$(basename ${SPLASH_IMAGE})|" \ + -e "s|@@KERNVER@@|${KERNELVERSION}|" \ + -e "s|@@KEYMAP@@|${KEYMAP}|" \ + -e "s|@@ARCH@@|$BASE_ARCH|" \ + -e "s|@@LOCALE@@|${LOCALE}|" \ + -e "s|@@BOOT_TITLE@@|${BOOT_TITLE}|" \ + -e "s|@@BOOT_CMDLINE@@|${BOOT_CMDLINE}|" \ + $PXELINUX_DIR/default +} + +generate_netboot_tarball() { + cd $IMAGEDIR/tftp + tar -zcvf $CURDIR/$OUTPUT_FILE.tar.gz . + cd $CURDIR +} + +# +# main() +# +while getopts "a:b:r:c:C:T:Kk:l:i:o:p:h" opt; do + case $opt in + a) BASE_ARCH="$OPTARG";; + b) BASE_SYSTEM_PKG="$OPTARG";; + r) XBPS_REPOSITORY="--repository=$OPTARG $XBPS_REPOSITORY";; + c) XBPS_CACHEDIR="--cachedir=$OPTARG";; + K) readonly KEEP_BUILDDIR=1;; + k) KEYMAP="$OPTARG";; + l) LOCALE="$OPTARG";; + i) INITRAMFS_COMPRESSION="$OPTARG";; + o) OUTPUT_FILE="$OPTARG";; + p) PACKAGE_LIST="$OPTARG";; + C) BOOT_CMDLINE="$OPTARG";; + T) BOOT_TITLE="$OPTARG";; + h) usage;; + esac +done +shift $((OPTIND - 1)) + +XBPS_REPOSITORY="$XBPS_REPOSITORY --repository=http://repo.voidlinux.eu/current --repository=http://repo.voidlinux.eu/current/musl" + +ARCH=$(xbps-uhelper arch) + +# Set defaults +: ${BASE_ARCH:=$(uname -m)} +: ${XBPS_CACHEDIR:=-c $(pwd -P)/xbps-cachedir-${BASE_ARCH}} +: ${XBPS_HOST_CACHEDIR:=-c $(pwd -P)/xbps-cachedir-${ARCH}} +: ${KEYMAP:=us} +: ${LOCALE:=en_US.UTF-8} +: ${INITRAMFS_COMPRESSION:=xz} +: ${SQUASHFS_COMPRESSION:=xz} +: ${BASE_SYSTEM_PKG:=base-system} +: ${BOOT_TITLE:="Void Linux"} + +# Required packages in the image for a working system. +PACKAGE_LIST="$BASE_SYSTEM_PKG $PACKAGE_LIST" + +# Check for root permissions. +if [ "$(id -u)" -ne 0 ]; then + die "Must be run as root, exiting..." +fi + +readonly CURDIR="$PWD" + +ISO_VOLUME="VOID_LIVE" +if [ -n "$ROOTDIR" ]; then + BUILDDIR=$(mktemp --tmpdir="$ROOTDIR" -d) +else + BUILDDIR=$(mktemp --tmpdir="$(pwd -P)" -d) +fi +BUILDDIR=$(readlink -f $BUILDDIR) +IMAGEDIR="$BUILDDIR/image" +ROOTFS="$IMAGEDIR/rootfs" +VOIDHOSTDIR="$BUILDDIR/void-host" +BOOT_DIR="$IMAGEDIR/tftp" +PXELINUX_DIR="$BOOT_DIR/pxelinux.cfg" +PXELINUX_CFG="$PXELINUX_DIR/default" +CURRENT_STEP=0 +STEP_COUNT=6 +[ -n "${INCLUDE_DIRECTORY}" ] && ((STEP_COUNT=STEP_COUNT+1)) + +: ${SYSLINUX_DATADIR:=$VOIDHOSTDIR/usr/share/syslinux} +: ${SPLASH_IMAGE:=data/splash.png} +: ${XBPS_INSTALL_CMD:=xbps-install} +: ${XBPS_REMOVE_CMD:=xbps-remove} +: ${XBPS_QUERY_CMD:=xbps-query} +: ${XBPS_RINDEX_CMD:=xbps-rindex} +: ${XBPS_UHELPER_CMD:=xbps-uhelper} +: ${XBPS_RECONFIGURE_CMD:=xbps-reconfigure} + +mkdir -p $ROOTFS $VOIDHOSTDIR $PXELINUX_DIR + +print_step "Synchronizing XBPS repository data..." +copy_void_keys $ROOTFS +copy_void_keys $VOIDHOSTDIR +XBPS_ARCH=$BASE_ARCH $XBPS_INSTALL_CMD -r $ROOTFS ${XBPS_REPOSITORY} -S +XBPS_ARCH=$ARCH $XBPS_INSTALL_CMD -r $VOIDHOSTDIR $XBPS_REPOSITORY -S + +_linux_series=$(XBPS_ARCH=$BASE_ARCH $XBPS_QUERY_CMD -r $ROOTFS ${XBPS_REPOSITORY:=-R} -x linux|head -1) +_kver=$(XBPS_ARCH=$BASE_ARCH $XBPS_QUERY_CMD -r $ROOTFS ${XBPS_REPOSITORY:=-R} -p pkgver ${_linux_series}) +KERNELVERSION=$($XBPS_UHELPER_CMD getpkgversion ${_kver}) + +: ${OUTPUT_FILE="void-netboot-${BASE_ARCH}-${KERNELVERSION}-$(date +%Y%m%d)"} + +print_step "Installing software to generate the image: ${REQUIRED_PKGS} ..." +install_prereqs + +mkdir -p "$ROOTFS"/etc +[ -s data/motd ] && cp data/motd $ROOTFS/etc +[ -s data/issue ] && cp data/issue $ROOTFS/etc + +print_step "Installing void pkgs into the rootfs: ${PACKAGE_LIST} ..." +install_packages + +print_step "Generating initramfs image ($INITRAMFS_COMPRESSION)..." +generate_initramfs + +print_step "Generating pxelinux support..." +generate_pxelinux_boot + +print_step "Generating netboot tarball..." +generate_netboot_tarball + +info_msg "Created $(readlink -f $CURDIR/$OUTPUT_FILE) ($hsize) successfully." diff --git a/pxelinux.cfg/pxelinux.cfg.in b/pxelinux.cfg/pxelinux.cfg.in new file mode 100644 index 0000000..63456ae --- /dev/null +++ b/pxelinux.cfg/pxelinux.cfg.in @@ -0,0 +1,36 @@ +UI vesamenu.c32 +PROMPT 0 +TIMEOUT 100 +ONTIMEOUT c + +MENU TABMSG Press ENTER to boot or TAB to edit a menu entry +MENU AUTOBOOT BIOS default device boot in # second{,s}... +MENU BACKGROUND @@SPLASHIMAGE@@ +MENU WIDTH 78 +MENU MARGIN 1 +MENU ROWS 4 +MENU VSHIFT 2 +MENU TIMEOUTROW 8 +MENU TABMSGROW 2 +MENU CMDLINEROW 11 +MENU HELPMSGROW 16 +MENU HELPMSGENDROW 29 + +MENU COLOR title * #FF5255FF * +MENU COLOR border * #00000000 #00000000 none +MENU COLOR sel * #ffffffff #FF5255FF * + +LABEL menu +MENU LABEL Interactive Session [@@BOOT_TITLE@@] (@@KERNVER@@ @@ARCH@@) +KERNEL vmlinuz +APPEND initrd=initrd root=/dev/null loglevel=4 vconsole.unicode=1 vconsole.keymap=@@KEYMAP@@ locale.LANG=@@LOCALE@@ @@BOOT_CMDLINE@@ + +LABEL auto +MENU LABEL AutoInstall [@@BOOT_TITLE@@] (@@KERNVER@@ @@ARCH@@) +KERNEL vmlinuz +APPEND initrd=initrd root=/dev/null auto loglevel=4 vconsole.unicode=1 vconsole.keymap=@@KEYMAP@@ locale.LANG=@@LOCALE@@ @@BOOT_CMDLINE@@ + +LABEL c +MENU LABEL Boot first HD found by BIOS +COM32 chain.c32 +APPEND hd0