I am setting up a network autoinstall with the 22.04.2 image. With a packages
key, the package installation step fails. (I thought it was working last week.) When I look into the target environment, all apt sources except cdrom
are missing:
ubuntu-server@ca2-t-it02:~$ ls -la /target/etc/apt/sources.list.d/
total 8
drwxr-xr-x 2 root root 4096 Apr 8 2022 .
drwxr-xr-x 8 root root 4096 Apr 5 21:48 ..
ubuntu-server@ca2-t-it02:~$ cat /target/etc/apt/sources.list
deb [check-date=no] file:///cdrom jammy main restricted
If I remove the packages
key and interrupt the install by forcing an error in late-commands
, sources.list
looks correct at that point. So it looks like I can get around this by doing the installs in late-commands
, but it would be much nicer if it worked as advertised (https://ubuntu.com/server/docs/install/autoinstall-reference#packages).
Here's my autoinstall file:
#cloud-config
autoinstall:
version: 1
apt:
geoip: false
preserve_sources_list: false
primary:
- arches: ["default"]
uri: http://us.archive.ubuntu.com/ubuntu/
timezone: UTC
identity:
hostname: newhost.example.com
realname: Local Administrator
username: myadmin
password: "<redacted>"
keyboard: {layout: us, toggle: null, variant: ''}
locale: en_US.UTF-8
network:
version: 2
ethernets:
srvnet:
match:
macaddress: '00:50:56:b3:bc:c9'
set-name: mynet
dhcp4: false
dhcp6: false
addresses: [ 10.1.1.213/24 ]
gateway4: 10.1.1.1
nameservers:
search: [ example.com ]
addresses: ["10.1.100.10", "10.2.100.10"]
ssh:
allow-pw: true
authorized-keys: []
install-server: true
packages:
- sssd-ad
- sssd-tools
- realmd
updates: all
storage:
layout:
name: lvm