#!/bin/sh
# auto/config - live-build configuration for the bty live env.
#
# live-build invokes this script when (re)configuring the build dir
# (typically the first ``lb build`` run). Encodes our lb config args:
# Debian trixie, amd64, netboot output (kernel + initrd + squashfs),
# no debian-installer, no memtest, no apt recommends, no security.
#
# Requires live-build 20240208+ (Debian trixie or newer) which
# fetches ``dists/<release>/main/Contents-<arch>.gz`` from the
# per-component layout Debian now publishes. Ubuntu's stock
# live-build 20230502 still uses the obsolete top-level URL and
# 404s on every active Debian release; release.yml's live job
# pulls the trixie .deb explicitly to work around that.
set -e

lb config noauto \
    --mode debian \
    --distribution trixie \
    --architectures amd64 \
    --binary-images netboot \
    --debian-installer false \
    --memtest none \
    --apt-recommends false \
    --security false \
    --bootappend-live "boot=live components quiet noeject" \
    "${@}"
