File tree Expand file tree Collapse file tree 1 file changed +7
-22
lines changed
Expand file tree Collapse file tree 1 file changed +7
-22
lines changed Original file line number Diff line number Diff line change 171171[[ -d /boot/efi ]] || mkdir /boot/efi
172172mount -a
173173
174- # cloud-init will find the network interface from metadata but we must source
175- # the files from 'interfaces.d' to get debian to put them into effect
176- cat <<EOF > /etc/network/interfaces
177- source /etc/network/interfaces.d/*
178-
179- auto lo
180- iface lo inet loopback
181- EOF
182-
183- echo "vm-instance" > /etc/hostname
184-
185- cat <<EOF > /etc/hosts
186- 127.0.0.1 localhost
187- 127.0.1.1 vm-instance
188-
189- # The following lines are desirable for IPv6 capable hosts
190- ::1 localhost ip6-localhost ip6-loopback
191- ff02::1 ip6-allnodes
192- ff02::2 ip6-allrouters
193- EOF
194-
195174debconf-set-selections <<EOF
196175tzdata tzdata/Areas select America
197176tzdata tzdata/Zones/America select Los_Angeles
211190
212191# Stop anything overriding debconf's settings
213192rm -f /etc/default/locale /etc/locale.gen /etc/default/keyboard
214- DEBIAN_FRONTEND=noninteractive apt-get install --assume-yes locales linux-image-amd64 grub-efi-amd64 overlayroot cloud-init
193+ DEBIAN_FRONTEND=noninteractive apt-get install --assume-yes locales linux-image-amd64 grub-efi-amd64 overlayroot cloud-init openssh-server
194+ DEBIAN_FRONTEND=noninteractive apt-get remove --assume-yes ifupdown
195+
196+ # ifupdown & cloud-init don't play well together in debian 13
197+ # cloud-init generates an ` inet6` line for ipv6 dhcp and dhclient doesn't like these
198+ # https://lists.debian.org/debian-devel/2025/10/msg00201.html
199+ systemctl enable systemd-networkd
215200
216201# Add console=ttyS0 so we get early boot messages on the serial console.
217202sed -i -e 's/^\\ (GRUB_CMDLINE_LINUX="[^"]*\\ )"$/\\ 1 console=ttyS0"/' /etc/default/grub
You can’t perform that action at this time.
0 commit comments