Better setup for building the ISO.
parent
9ed8f3b146
commit
7c93bd0e57
|
@ -1,4 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
# This runs _inside_ the container to install dependencies and to execute the
|
||||||
|
# live-build steps that actually build the live image.
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
apt-get update
|
apt-get update
|
||||||
|
|
|
@ -1,14 +1,21 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
# This runs the build-iso script inside a docker container with volume mounts
|
||||||
|
# for input, output, and cached data.
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
IMAGE=debian:bookworm-slim
|
IMAGE=debian:bookworm-slim
|
||||||
echo "${PWD}"
|
|
||||||
|
MYREL="$( dirname "$( realpath "${0}" )" )/.."
|
||||||
|
MYCWD="$( realpath "${MYREL}" )"
|
||||||
|
MYREV="$( git -C "${MYCWD}" rev-parse --short=8 HEAD )"
|
||||||
|
echo "${MYCWD}"
|
||||||
|
|
||||||
docker volume create live-build-cache || true
|
docker volume create live-build-cache || true
|
||||||
#docker run --privileged --rm --workdir /app --env _DEBUG="${LB_DEBUG:-false}" \
|
docker run --privileged --rm --workdir /app \
|
||||||
docker run --privileged --workdir /app --env _DEBUG="${LB_DEBUG:-false}" \
|
--env _DEBUG="${LB_DEBUG:-false}" \
|
||||||
|
--env _BUILD_REV="${BUILD_REV:-${MYREV}}" \
|
||||||
--volume "live-build-cache:/app/build/cache" \
|
--volume "live-build-cache:/app/build/cache" \
|
||||||
--volume "${PWD}/bin:/app/bin" \
|
--volume "${MYCWD}/bin:/app/bin" \
|
||||||
--volume "${PWD}/dist:/app/dist" \
|
--volume "${MYCWD}/dist:/app/dist" \
|
||||||
--volume "${PWD}/live-build:/app/live-build" \
|
--volume "${MYCWD}/live-build:/app/live-build" \
|
||||||
"${IMAGE}" "bin/build-iso"
|
"${IMAGE}" "bin/build-iso"
|
||||||
|
|
|
@ -3,14 +3,22 @@
|
||||||
# see 'man lb config'
|
# see 'man lb config'
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
lb clean
|
||||||
lb config noauto \
|
lb config noauto \
|
||||||
--clean \
|
--clean \
|
||||||
--ignore-system-defaults \
|
--ignore-system-defaults \
|
||||||
--mode debian \
|
--distribution "bookworm" \
|
||||||
--debian-installer "none" \
|
--debian-installer "none" \
|
||||||
|
--firmware-chroot "false" \
|
||||||
--linux-packages "linux-image" \
|
--linux-packages "linux-image" \
|
||||||
|
--bootappend-live "boot=live components quiet splash noeject" \
|
||||||
--archive-areas "main contrib non-free-firmware non-free" \
|
--archive-areas "main contrib non-free-firmware non-free" \
|
||||||
--mirror-bootstrap "http://cdn.debian.net/debian/" \
|
--mirror-bootstrap "http://cdn.debian.net/debian/" \
|
||||||
--mirror-chroot "http://cdn.debian.net/debian/" \
|
--mirror-chroot "http://cdn.debian.net/debian/" \
|
||||||
--firmware-chroot "false" \
|
--backports "true" \
|
||||||
|
--updates "true" \
|
||||||
|
--iso-application "Proxmox Live" \
|
||||||
|
--iso-publisher "LE SRE" \
|
||||||
|
--iso-volume "${_BUILD_REV}:@ISOVOLUME_TS@" \
|
||||||
|
--image-name "live-proxmox-${_BUILD_REV}" \
|
||||||
"${@}"
|
"${@}"
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
binary
|
||||||
|
bootstrap
|
||||||
|
chroot
|
||||||
|
common
|
||||||
|
source
|
|
@ -1,119 +0,0 @@
|
||||||
# config/binary - options for live-build(7), binary stage
|
|
||||||
|
|
||||||
# Set image type
|
|
||||||
LB_IMAGE_TYPE="iso-hybrid"
|
|
||||||
|
|
||||||
# Set image filesystem
|
|
||||||
LB_BINARY_FILESYSTEM="fat32"
|
|
||||||
|
|
||||||
# Set apt/aptitude generic indices
|
|
||||||
LB_APT_INDICES="true"
|
|
||||||
|
|
||||||
# Set boot parameters
|
|
||||||
LB_BOOTAPPEND_LIVE="boot=live components quiet splash"
|
|
||||||
|
|
||||||
# Set boot parameters
|
|
||||||
LB_BOOTAPPEND_INSTALL=""
|
|
||||||
|
|
||||||
# Set boot parameters
|
|
||||||
LB_BOOTAPPEND_LIVE_FAILSAFE="boot=live components memtest noapic noapm nodma nomce nolapic nosmp nosplash vga=788"
|
|
||||||
|
|
||||||
# Set BIOS bootloader
|
|
||||||
LB_BOOTLOADER_BIOS="syslinux"
|
|
||||||
|
|
||||||
# Set EFI bootloader
|
|
||||||
LB_BOOTLOADER_EFI="grub-efi"
|
|
||||||
|
|
||||||
# Set bootloaders
|
|
||||||
LB_BOOTLOADERS=""
|
|
||||||
|
|
||||||
# Set checksums
|
|
||||||
LB_CHECKSUMS="sha256"
|
|
||||||
|
|
||||||
# Set compression
|
|
||||||
LB_COMPRESSION="none"
|
|
||||||
|
|
||||||
# Support dm-verity on rootfs
|
|
||||||
LB_DM_VERITY=""
|
|
||||||
|
|
||||||
# Support FEC on dm-verity rootfs
|
|
||||||
LB_DM_VERITY_FEC_ROOTS=""
|
|
||||||
|
|
||||||
# Set sign script for roothash for dm-verity rootfs
|
|
||||||
LB_DM_VERITY_SIGN=""
|
|
||||||
|
|
||||||
# Set zsync
|
|
||||||
LB_ZSYNC="true"
|
|
||||||
|
|
||||||
# Control if we build binary images chrooted
|
|
||||||
# NEVER, *EVER*, *E*V*E*R* SET THIS OPTION to false.
|
|
||||||
LB_BUILD_WITH_CHROOT="true"
|
|
||||||
|
|
||||||
# Set debian-installer
|
|
||||||
LB_DEBIAN_INSTALLER="none"
|
|
||||||
|
|
||||||
# Set debian-installer suite
|
|
||||||
LB_DEBIAN_INSTALLER_DISTRIBUTION="bullseye"
|
|
||||||
|
|
||||||
# Set debian-installer preseed filename/url
|
|
||||||
LB_DEBIAN_INSTALLER_PRESEEDFILE=""
|
|
||||||
|
|
||||||
# Toggle use of GUI debian-installer
|
|
||||||
LB_DEBIAN_INSTALLER_GUI="true"
|
|
||||||
|
|
||||||
# Set hdd label
|
|
||||||
LB_HDD_LABEL="DEBIAN_LIVE"
|
|
||||||
|
|
||||||
# Set hdd filesystem size
|
|
||||||
LB_HDD_SIZE="auto"
|
|
||||||
|
|
||||||
# Set start of partition for the hdd target for BIOSes that expect a specific boot partition start (e.g. "63s"). If empty, use optimal layout.
|
|
||||||
LB_HDD_PARTITION_START=""
|
|
||||||
|
|
||||||
# Set iso author
|
|
||||||
LB_ISO_APPLICATION="Debian Live"
|
|
||||||
|
|
||||||
# Set iso preparer
|
|
||||||
LB_ISO_PREPARER="live-build @LB_VERSION@; https://salsa.debian.org/live-team/live-build"
|
|
||||||
|
|
||||||
# Set iso publisher
|
|
||||||
LB_ISO_PUBLISHER="Debian Live project; https://wiki.debian.org/DebianLive; debian-live@lists.debian.org"
|
|
||||||
|
|
||||||
# Set iso volume (max 32 chars)
|
|
||||||
LB_ISO_VOLUME="Debian bullseye @ISOVOLUME_TS@"
|
|
||||||
|
|
||||||
# Set jffs2 eraseblock size
|
|
||||||
LB_JFFS2_ERASEBLOCK=""
|
|
||||||
|
|
||||||
# Set memtest
|
|
||||||
LB_MEMTEST="none"
|
|
||||||
|
|
||||||
# Set loadlin
|
|
||||||
LB_LOADLIN="false"
|
|
||||||
|
|
||||||
# Set win32-loader
|
|
||||||
LB_WIN32_LOADER="false"
|
|
||||||
|
|
||||||
# Set net tarball
|
|
||||||
LB_NET_TARBALL="true"
|
|
||||||
|
|
||||||
# Set onie
|
|
||||||
LB_ONIE="false"
|
|
||||||
|
|
||||||
# Set onie additional kernel cmdline options
|
|
||||||
LB_ONIE_KERNEL_CMDLINE=""
|
|
||||||
|
|
||||||
# Set inclusion of firmware packages in debian-installer
|
|
||||||
LB_FIRMWARE_BINARY="true"
|
|
||||||
|
|
||||||
# Set inclusion of firmware packages in the live image
|
|
||||||
LB_FIRMWARE_CHROOT="false"
|
|
||||||
|
|
||||||
# Set swap file path
|
|
||||||
LB_SWAP_FILE_PATH=""
|
|
||||||
|
|
||||||
# Set swap file size
|
|
||||||
LB_SWAP_FILE_SIZE="512"
|
|
||||||
|
|
||||||
# Enable/disable UEFI secure boot support
|
|
||||||
LB_UEFI_SECURE_BOOT="auto"
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
include menu.cfg
|
||||||
|
default vesamenu.c32
|
||||||
|
prompt 0
|
||||||
|
timeout 60
|
|
@ -1,76 +0,0 @@
|
||||||
# config/bootstrap - options for live-build(7), bootstrap stage
|
|
||||||
|
|
||||||
# Select architecture to use
|
|
||||||
LB_ARCHITECTURE="amd64"
|
|
||||||
|
|
||||||
# Select distribution to use
|
|
||||||
LB_DISTRIBUTION="bullseye"
|
|
||||||
|
|
||||||
# Select parent distribution to use
|
|
||||||
LB_PARENT_DISTRIBUTION="bookworm"
|
|
||||||
|
|
||||||
# Select distribution to use in the chroot
|
|
||||||
LB_DISTRIBUTION_CHROOT="bullseye"
|
|
||||||
|
|
||||||
# Select parent distribution to use in the chroot
|
|
||||||
LB_PARENT_DISTRIBUTION_CHROOT="bookworm"
|
|
||||||
|
|
||||||
# Select distribution to use in the final image
|
|
||||||
LB_DISTRIBUTION_BINARY="bullseye"
|
|
||||||
|
|
||||||
# Select parent distribution to use in the final image
|
|
||||||
LB_PARENT_DISTRIBUTION_BINARY="bookworm"
|
|
||||||
|
|
||||||
# Select parent distribution for debian-installer to use
|
|
||||||
LB_PARENT_DEBIAN_INSTALLER_DISTRIBUTION="bookworm"
|
|
||||||
|
|
||||||
# Select archive areas to use
|
|
||||||
LB_ARCHIVE_AREAS="main contrib non-free-firmware non-free"
|
|
||||||
|
|
||||||
# Select parent archive areas to use
|
|
||||||
LB_PARENT_ARCHIVE_AREAS="main contrib non-free-firmware non-free"
|
|
||||||
|
|
||||||
# Set parent mirror to bootstrap from
|
|
||||||
LB_PARENT_MIRROR_BOOTSTRAP="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set parent mirror to fetch packages from
|
|
||||||
LB_PARENT_MIRROR_CHROOT="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set security parent mirror to fetch packages from
|
|
||||||
LB_PARENT_MIRROR_CHROOT_SECURITY="http://security.debian.org/"
|
|
||||||
|
|
||||||
# Set parent mirror which ends up in the image
|
|
||||||
LB_PARENT_MIRROR_BINARY="http://deb.debian.org/debian/"
|
|
||||||
|
|
||||||
# Set security parent mirror which ends up in the image
|
|
||||||
LB_PARENT_MIRROR_BINARY_SECURITY="http://security.debian.org/"
|
|
||||||
|
|
||||||
# Set debian-installer parent mirror
|
|
||||||
LB_PARENT_MIRROR_DEBIAN_INSTALLER="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set mirror to bootstrap from
|
|
||||||
LB_MIRROR_BOOTSTRAP="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set mirror to fetch packages from
|
|
||||||
LB_MIRROR_CHROOT="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set security mirror to fetch packages from
|
|
||||||
LB_MIRROR_CHROOT_SECURITY="http://security.debian.org/"
|
|
||||||
|
|
||||||
# Set mirror which ends up in the image
|
|
||||||
LB_MIRROR_BINARY="http://deb.debian.org/debian/"
|
|
||||||
|
|
||||||
# Set security mirror which ends up in the image
|
|
||||||
LB_MIRROR_BINARY_SECURITY="http://security.debian.org/"
|
|
||||||
|
|
||||||
# Set debian-installer mirror
|
|
||||||
LB_MIRROR_DEBIAN_INSTALLER="http://cdn.debian.net/debian/"
|
|
||||||
|
|
||||||
# Set architectures to use foreign bootstrap
|
|
||||||
LB_BOOTSTRAP_QEMU_ARCHITECTURE=""
|
|
||||||
|
|
||||||
# Set packages to exclude during foreign bootstrap
|
|
||||||
LB_BOOTSTRAP_QEMU_EXCLUDE=""
|
|
||||||
|
|
||||||
# Set static qemu binary for foreign bootstrap
|
|
||||||
LB_BOOTSTRAP_QEMU_STATIC=""
|
|
|
@ -1,34 +0,0 @@
|
||||||
# config/chroot - options for live-build(7), chroot stage
|
|
||||||
|
|
||||||
# Set chroot filesystem
|
|
||||||
LB_CHROOT_FILESYSTEM="squashfs"
|
|
||||||
|
|
||||||
# Set chroot squashfs compression level
|
|
||||||
LB_CHROOT_SQUASHFS_COMPRESSION_LEVEL=""
|
|
||||||
|
|
||||||
# Set chroot squashfs compression type
|
|
||||||
LB_CHROOT_SQUASHFS_COMPRESSION_TYPE=""
|
|
||||||
|
|
||||||
# Set union filesystem
|
|
||||||
LB_UNION_FILESYSTEM="overlay"
|
|
||||||
|
|
||||||
# Set interactive build
|
|
||||||
LB_INTERACTIVE="false"
|
|
||||||
|
|
||||||
# Set keyring packages
|
|
||||||
LB_KEYRING_PACKAGES="debian-archive-keyring"
|
|
||||||
|
|
||||||
# Set kernel flavour to use (with arch)
|
|
||||||
LB_LINUX_FLAVOURS_WITH_ARCH="amd64"
|
|
||||||
|
|
||||||
# Set kernel packages to use
|
|
||||||
LB_LINUX_PACKAGES="linux-image"
|
|
||||||
|
|
||||||
# Enable security updates
|
|
||||||
LB_SECURITY="true"
|
|
||||||
|
|
||||||
# Enable updates updates
|
|
||||||
LB_UPDATES="true"
|
|
||||||
|
|
||||||
# Enable backports updates
|
|
||||||
LB_BACKPORTS="false"
|
|
|
@ -1,102 +0,0 @@
|
||||||
# config/common - common options for live-build(7)
|
|
||||||
|
|
||||||
# Version of live-build used to build config (config format version)
|
|
||||||
LB_CONFIGURATION_VERSION="20230502"
|
|
||||||
|
|
||||||
# Set package manager
|
|
||||||
LB_APT="apt"
|
|
||||||
|
|
||||||
# Set proxy for HTTP connections
|
|
||||||
LB_APT_HTTP_PROXY=""
|
|
||||||
|
|
||||||
# Set apt/aptitude pipeline depth
|
|
||||||
LB_APT_PIPELINE=""
|
|
||||||
|
|
||||||
# Set apt/aptitude recommends
|
|
||||||
LB_APT_RECOMMENDS="true"
|
|
||||||
|
|
||||||
# Set apt/aptitude security
|
|
||||||
LB_APT_SECURE="true"
|
|
||||||
|
|
||||||
# Set apt/aptitude source entries in sources.list
|
|
||||||
LB_APT_SOURCE_ARCHIVES="true"
|
|
||||||
|
|
||||||
# Control cache
|
|
||||||
LB_CACHE="true"
|
|
||||||
|
|
||||||
# Control if downloaded package indices should be cached
|
|
||||||
LB_CACHE_INDICES="false"
|
|
||||||
|
|
||||||
# Control if downloaded packages files should be cached
|
|
||||||
LB_CACHE_PACKAGES="true"
|
|
||||||
|
|
||||||
# Control if completed stages should be cached
|
|
||||||
LB_CACHE_STAGES="bootstrap"
|
|
||||||
|
|
||||||
# Set debconf(1) frontend to use
|
|
||||||
LB_DEBCONF_FRONTEND="noninteractive"
|
|
||||||
|
|
||||||
# Set debconf(1) priority to use
|
|
||||||
LB_DEBCONF_PRIORITY="critical"
|
|
||||||
|
|
||||||
# Set initramfs hook
|
|
||||||
LB_INITRAMFS="live-boot"
|
|
||||||
|
|
||||||
# Set initramfs compression
|
|
||||||
LB_INITRAMFS_COMPRESSION="gzip"
|
|
||||||
|
|
||||||
# Set init system
|
|
||||||
LB_INITSYSTEM="systemd"
|
|
||||||
|
|
||||||
# Set distribution mode
|
|
||||||
LB_MODE="debian"
|
|
||||||
|
|
||||||
# Set system type
|
|
||||||
LB_SYSTEM="live"
|
|
||||||
|
|
||||||
# Set base name of the image
|
|
||||||
LB_IMAGE_NAME="live-image"
|
|
||||||
|
|
||||||
# Set options to use with apt
|
|
||||||
APT_OPTIONS="--yes -o Acquire::Retries=5"
|
|
||||||
|
|
||||||
# Set options to use with aptitude
|
|
||||||
APTITUDE_OPTIONS="--assume-yes -o Acquire::Retries=5"
|
|
||||||
|
|
||||||
# Set options to use with debootstrap
|
|
||||||
DEBOOTSTRAP_OPTIONS=""
|
|
||||||
|
|
||||||
# Set script to use with debootstrap
|
|
||||||
DEBOOTSTRAP_SCRIPT=""
|
|
||||||
|
|
||||||
# Set options to use with gzip
|
|
||||||
GZIP_OPTIONS="-6 --rsyncable"
|
|
||||||
|
|
||||||
# Enable UTC timestamps
|
|
||||||
LB_UTC_TIME="false"
|
|
||||||
|
|
||||||
# live-build options
|
|
||||||
|
|
||||||
# Enable breakpoints
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_BREAKPOINTS="false"
|
|
||||||
|
|
||||||
# Enable debug
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_DEBUG="false"
|
|
||||||
|
|
||||||
# Enable color
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_COLOR="auto"
|
|
||||||
|
|
||||||
# Enable force
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_FORCE="false"
|
|
||||||
|
|
||||||
# Enable quiet
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_QUIET="false"
|
|
||||||
|
|
||||||
# Enable verbose
|
|
||||||
# If set here, overrides the command line option
|
|
||||||
#_VERBOSE="false"
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
#!/bin/sh
|
||||||
|
set -e
|
||||||
|
|
||||||
|
sed -i -e '/- update_etc_hosts/d' /etc/cloud/cloud.cfg
|
|
@ -0,0 +1,2 @@
|
||||||
|
cloud-init
|
||||||
|
cloud-guest-utils
|
|
@ -0,0 +1 @@
|
||||||
|
openvswitch-switch
|
|
@ -0,0 +1 @@
|
||||||
|
qemu-guest-agent
|
|
@ -1,3 +1,4 @@
|
||||||
cmatrix
|
cmatrix
|
||||||
tree
|
tree
|
||||||
tmux
|
tmux
|
||||||
|
bind9-dnsutils
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
# config/source - options for live-build(7), source stage
|
|
||||||
|
|
||||||
# Set source option
|
|
||||||
LB_SOURCE="false"
|
|
||||||
|
|
||||||
# Set image type
|
|
||||||
LB_SOURCE_IMAGES="tar"
|
|
Loading…
Reference in New Issue