Skip to content

Latest commit

 

History

History
158 lines (98 loc) · 5.23 KB

README.md

File metadata and controls

158 lines (98 loc) · 5.23 KB

Project Objective

This project provides tools to create ISO images for general use, originally developed for kitting TX120s7 and Thinkpad x220/x230 and for Ubuntu 20.04 LTS.

It supports AutoInstall for Ubuntu 22.04 and later versions.

History

  • 2025/03/21

    • Updated the base ISO image filename.
  • 2024/04/26

    • Support the Ubuntu 24.04 Desktop and Server versions now.
    • Changed the github repository name to ub-autoinstall-iso

References

As of 22.04, the EFI boot image (boot/grub/efi.img) is no longer included in the ISO image.

Please refer to the following document for more details and a workaround if you are interested the way of creating original ISO image files.

Instructions for use

Install the required packages.

$ sudo apt update
$ sudo apt install git make sudo

Checkout the target tag which you would like to install.

$ sudo git checkout refs/tags/24.04.2 -b my_24.04.2

To download the ISO image and populate the initial files, the following tasks are performed only once.

$ make download
$ make init

The following tasks must be performed each time an ISO file is generated;

$ make setup
$ make geniso

The geniso task might be failed due to the locale, so it is safe to specify LANG=C.

If you want to specify a LANG other than "C", change the GENISO_LANG value in the Makefile.

config/user-data file

Customization of the installation process focuses on config/user-data.

  • config/user-data.efi - Configuration to create ESP area for UEFI boot
  • config/user-data.mbr - Configuration for MBR (BIOS) boot (if the system never boot with the user-data-.efi.)

Please place the preferred configuration file as the config/user-data.

The config/user-data.efi file is linked as config/user-data as the default setting.

If your system doesn't support the EFI boot, please use the config/user-data.mbr, instead.

The following is a summary of the major setting parameters.

config/boot/grub/grub.cfg file

If you would like to use any headless server which doesn't have video output, but has a serial console, please enable the following line of config/boot/grub/grub.cfg file.

linux	/casper/vmlinuz autoinstall "ds=nocloud-net;s=file:///cdrom/" quiet  --- console=ttyS0,115200n8

Delete the existing line or comment-out the existing line as follows.

## linux	/casper/vmlinuz autoinstall "ds=nocloud-net;s=file:///cdrom/" quiet ---

The tested system, such as x230, can work well even the "console=ttyS0,115200n8" setting was specified. However, other systems, such as x270, couldn't work well, so please take care of the setting.

Default user password

Change the username: and password: lines in user-data as desired.

  • ID: ubuntu
  • Password: secret

The hash value specified in the password: line was generated by the following command.

$ openssl passwd -6 -salt "$(openssl rand -hex 8)" secret

Other settings

The sudoers file is arranged for use with Ansible

This includes a sudoers file that has been set so that no password is required for the user “ubuntu”.

If you want to change this, please edit the contents of config/extras/ubuntu.sudoers.

SSH keys

Following is an example for providing ssh keys to the default user, ubuntu.

ssh:
  authorized-keys:
    - "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAAIH8mvfUPhRddvGXBxGcvwo5m3CRVOf8RbFXwaUa9mhLX comment"
    - "..."

Support for APU/APU2 or other old machines

APU and some old IA servers, such as RX100 S7, should use the isolinux.

The following configurations are made to work with devices that only have a serial terminal.

  • Add console=ttyS0,115200n8 to the end of the "append" line in config/isolinux/txt.cfg
  • Add console=ttyS0,115200n8 to the end of the "linux" line in config/boot/grub/grub.cfg.
  • Add some isolinux related tasks to Makefile

To create an ISO image for installation on the APU/APU2 from a USB stick, please conduct added tasks as follows,

Perform the following procedures only the first time. If you perform repeatedly, there is no side-effects.

$ make download
$ make init
$ make setup-isolinux
$ ln -fs user-data.mbr config/user-data
$ sed -i -e 's/---$/--- console=ttyS0,115200n8/' config/boot/grub/grub.cfg

Repeat the following steps after editing the user-data file to generate an ISO image.

$ make setup
$ make geniso-isolinux

LICENSE

Copyright 2023-2025 Yasuhiro ABE, <[email protected], [email protected]>

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.