This project provides a fully automated, hands-free installation for Ubuntu Desktop 24.04 LTS (Noble Numbat) using the autoinstall.yaml mechanism. Starting with Ubuntu 24.04.1, the Desktop installer fully supports the same autoinstall functionality as Ubuntu Server.
This README includes instructions to prepare your bootable drive, configure your autoinstall file, and run the installation.
- Fully automated Desktop installation.
- Pre-configured sudo user.
- SSH server installation for Ansible/remote management.
- Automatic locale, timezone, keyboard, and network configuration.
- Post-installation commands and error handling.
- Ubuntu Desktop 24.04.1 ISO or newer.
- USB drive or second partition for the autoinstall file.
- SSH key pair (for passwordless access to the installed system).
- WSL (Windows Subsystem for Linux) or Linux host for building the bootable ISO.
Ubuntu autoinstall requires a hashed password for the default user.
openssl passwd -6Copy the resulting hash into your autoinstall.yaml under password.
Ensure your personal computer’s public SSH key is available. Add it to the authorized-keys section in the autoinstall.yaml:
ssh:
install-server: True
authorized-keys:
- ssh-ed25519 AAAAC3Nzac user@host
allow-pw: falseFor detailed guidance on generating SSH keys: SSH Key Generation
- Create a directory for your autoinstall files:
mkdir -p ~/autoinstall- Copy the ISO contents:
cp /mnt/c/Path/To/UbuntuISO.iso ~/autoinstall- Install ISO generation tools:
sudo apt update && sudo apt install -y genisoimage- Generate a bootable ISO:
genisoimage -o ~/autoinstall.iso -V AUTOINSTALL -r -J ~/autoinstall- Copy it back to your Windows desktop:
cp ~/autoinstall.iso /mnt/c/(Where ever you want)During installation:
- Skip any prompts until the autoinstall option appears.
- To locate your USB or attached autoinstall drive:
lsblk
sudo su
mkdir -p /media/autoinstall
mount /dev/sdb /media/autoinstall
ls /media/autoinstall
# Should show: autoinstall.yaml- Use the path for manual autoinstall if needed:
file:///media/autoinstall/autoinstall.yaml
-
Boot the Ubuntu 24.04.1 Desktop ISO.
-
If the installer does not auto-detect your
autoinstall.yaml, provide a manual path:- Press
Ctrl+Alt+F2(orCtrl+Alt+Tin GUI) to open a shell. - Attach your second drive or USB.
- List disks:
lsblk -f - Mount your autoinstall partition if needed.
- Restart to GRUB menu and append to the Linux line:
- Press
subiquity.autoinstallpath=/media/ubuntu/CONFIG/autoinstall.yaml
# Use spaces, no tabs
autoinstall:
version: 1
identity:
realname: "Your Name"
username: username
password: "<generated-hash>"
hostname: computer-name
group: sudo
interactive-sections:
- network
keyboard:
layout: "us"
locale: "en_US.UTF-8"
timezone: "America/New_York"
ssh:
install-server: True
authorized-keys:
- ssh-ed25519 AAAAC3Nzac user@host
allow-pw: false
early-commands:
- sudo apt update -y && sudo apt upgrade -y
shutdown: reboot
error-commands:
- tar -czf /installer-logs.tar.gz /var/log/installer
- journalctl -b > /installer-journal.log
late-commands:
- sudo apt update -y && sudo apt upgrade -y
- sudo systemctl start sshd
- sudo systemctl enable sshd
- sudo systemctl restart sshd
- firewall-cmd --service=ssh --permanent
- firewall-cmd --reload- Desktop ISOs do not include
openssh-serverby default, so network access is required. - Using a single sudo user during install simplifies repetitive deployments.
- For advanced post-install configurations, modify
late-commands.
- Autoinstall Quick Start Guide (Canonical) – Step-by-step guide for creating autoinstall configurations.
- Autoinstall Reference (Canonical) – Full documentation of all configuration options for
autoinstall.yaml. - SSH Key Generation – How to generate secure SSH key pairs.
- Subiquity 24.04.1 Release Notes – Updates and improvements in the latest Subiquity installer.
- Autoinstall Video Tutorial – Visual walkthrough of autoinstall setup and usage.