diff --git a/install.sh b/install.sh index 718742c..ace61cc 100755 --- a/install.sh +++ b/install.sh @@ -269,8 +269,13 @@ build_template() { local image="$WORKDIR/build-$id.img" # The cloud image's root filesystem is only ~2 GB, too small for Docker. # Grow the image by 4 GB and the root partition with it before installing. + # Classic eth0/eth1 NIC names: Proxmox cloud-init configures eth0..ethN, and + # Ubuntu 26.04 brings NICs up in the initramfs, so cloud-init can't rename them + # later and static IPs never apply on first boot. local -a customize=(--run-command 'growpart /dev/sda 1 && resize2fs /dev/sda1' - --install qemu-guest-agent) + --install qemu-guest-agent + --write '/etc/default/grub.d/99-net-ifnames.cfg:GRUB_CMDLINE_LINUX_DEFAULT="$GRUB_CMDLINE_LINUX_DEFAULT net.ifnames=0 biosdevname=0"' + --run-command 'update-grub') info "[$id] Preparing image for $name" cp "$BASE_IMAGE" "$image"