[Merge] ~dbungert/livecd-rootfs:ubuntu-mini-iso into livecd-rootfs:ubuntu/master
Dan Bungert
mp+436420 at code.launchpad.net
Tue Feb 28 02:17:17 UTC 2023
Diff comments:
> diff --git a/live-build/auto/config b/live-build/auto/config
> index 157f8b4..8d76bb7 100755
> --- a/live-build/auto/config
> +++ b/live-build/auto/config
> @@ -924,6 +929,27 @@ case $PROJECT in
> PREINSTALL_POOL_SEEDS='server-ship'
> ;;
>
> + ubuntu-mini-iso)
> + OPTS="${OPTS:+$OPTS }--bootstrap-flavour=minimal"
> +
> + OPTS="${OPTS:+$OPTS }--linux-packages=none --initramfs=none"
> + KERNEL_FLAVOURS=none
> + BINARY_REMOVE_LINUX=false
> +
> + PASSES_TO_LAYERS=true
The build should work with commit "ubuntu-mini-iso: allow squashfs output" removed, will confirm.
> + add_package ubuntu-mini-iso mini-iso-tools openssl ca-certificates isc-dhcp-client linux-generic
Yes, we should move these dependencies to mini-iso-tools.
busybox + casperize adds a requirement on openssl.
https://git.launchpad.net/ubuntu/+source/busybox/tree/debian/tree/busybox/usr/share/initramfs-tools/hooks/zz-busybox#n53
I'm blanking on the isc-dhcp-client requirement, something similar, I'll report back.
> + # keyboard-configuration plymouth
> + case $ARCH in
> + amd64)
> + add_package ubuntu-mini-iso cd-boot-images-amd64
> + ;;
> + *)
> + echo "unexpected architecture for $PROJECT: '$ARCH'"
> + exit 1
> + ;;
> + esac
> + ;;
> +
> ubuntu-base)
> OPTS="${OPTS:+$OPTS }--bootstrap-flavour=minimal"
> ;;
> diff --git a/live-build/ubuntu-mini-iso/hooks/01-mini-iso.binary b/live-build/ubuntu-mini-iso/hooks/01-mini-iso.binary
> new file mode 100755
> index 0000000..5d4b115
> --- /dev/null
> +++ b/live-build/ubuntu-mini-iso/hooks/01-mini-iso.binary
> @@ -0,0 +1,49 @@
> +#!/bin/sh
> +
> +set -eu
> +
> +case $ARCH in
> + amd64)
> + ;;
> + *)
> + exit 0
> + ;;
> +esac
> +
> +KERNEL=chroot/boot/vmlinuz
> +INITRD=chroot/boot/initrd.img
> +
> +mkdir -p "chroot/etc/initramfs-tools/conf.d"
> +cat > chroot/etc/initramfs-tools/conf.d/casperize.conf <<EOF
> +export CASPER_GENERATE_UUID=1
> +EOF
> +
> +chroot chroot update-initramfs -u
> +
> +case $ARCH in
> + amd64)
> + mkdir -p "ubuntu-mini-iso/amd64"
> + cp -a chroot/usr/share/cd-boot-images-amd64/tree ubuntu-mini-iso/amd64/tree
> + cp -a chroot/usr/share/cd-boot-images-amd64/images ubuntu-mini-iso/amd64/images
> + mkdir -p "ubuntu-mini-iso/amd64/tree/casper"
> + cp "$KERNEL" ubuntu-mini-iso/amd64/tree/casper/vmlinuz
> + cp "$INITRD" ubuntu-mini-iso/amd64/tree/casper/initrd
> + mkdir -p "ubuntu-mini-iso/amd64/tree/boot/grub"
> + cat > ubuntu-mini-iso/amd64/tree/boot/grub/grub.cfg <<EOF
> +menuentry "Choose an Ubuntu version to install" {
> + set gfxpayload=keep
> + linux /casper/vmlinuz iso-chooser-menu ip=dhcp ---
> + initrd /casper/initrd
> +}
> +EOF
Implementing that.
> + ;;
> +esac
> +
> +dest="${PWD}/livecd.${PROJECT}.ubuntu-mini.iso"
> +xorriso="$(cat chroot/usr/share/cd-boot-images-amd64/xorriso-cmd.txt)"
> +
> +cd ubuntu-mini-iso/$ARCH
> +$xorriso -o $dest
> +cd ../..
> +
> +# rm -rf ubuntu-mini-iso
--
https://code.launchpad.net/~dbungert/livecd-rootfs/+git/livecd-rootfs/+merge/436420
Your team Ubuntu Core Development Team is subscribed to branch livecd-rootfs:ubuntu/master.
More information about the Ubuntu-reviews
mailing list