A work in progress mkosi configuration around Arch Linux with the following goals:
- Bleeding Edge: Using CachyOS and Arch as a base to have the latest and greatest.
- Modern: Uses some of the newest best practices, such as using UKIs and containers.
- Secure: Secure Boot, Encrypted, TPM... All that goodness.
- Legacy Free: No GRUB, no BIOS support. By design.
This repository takes insipration from or gives credits to the following projects and resources:
- CachyOS Settings - Embedded into this configuration - Many of the settings here act as a baseline for this image.
If you would like to make a lot of changes, incremental builds are a good idea.
# Generate the default image
mkosi build --output=default
# Make some changes, then use an incremental build
mkosi -i boot
# For a consistent root password, set the hash
$ touch mkosi.rootpw
$ chmod 600 mkosi.rootpw
$ echo -n hashed: >>mkosi.rootpw
$ openssl passwd -6 >>mkosi.rootpw
# Or, if its one time only, consider setting it within the build image
systemd-nspawn --Image mkosi.output/default
passwd
mkosi -f --image-version=$(date --utc +%Y-%m-%d)
mkosi -f --image-version=$(git rev-parse --short=10 HEAD)-$(date --utc +%Y-%m-%d)
On bootup, the image will prompt you to create a user, managed by systemd-homed
. If you already have a homed
user, copying it to the image should 'just work'. Likewise if you flash an image to bare metal and plug in a homed
drive!
# Example for how to generate a systemd-homed user. Image path could be a USB key!
losetup --find --show --sector-size=4096 nurah.img
homectl create nurah --real-name="Nurah Wolfo" [email protected] --shell=/usr/bin/fish --member-of=wheel,libvirt --storage=luks --luks-discard=true --luks-offline-discard=true --uid=60069 --ssh-authorized-keys="ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGkFuzdCzeJ2B2KuUmRUTXErvo67RynDL/2/mBq9r+SW Nurah Wolfo <[email protected]> - Primary" --password-hint="Eat my butt" --fs-type=btrfs --image-path /dev/loop0
If flashed to bare metal, or used as a VM, consider asking the UEFI to boot the UKI directly, instead of the boot loader.
efibootmgr -c -d /dev/nvme0n1p1 -p 1 -L "Moshi" -l '\EFI\Linux\moshi.efi'
This project contains a lot of packages that I generally like. Some of them are called out below!
- bat - A cat clone with wings
- eza - A modern replacement for ls
- fastfetch - A feature-rich and performance oriented system information tool
- neovim - Vim-fork focused on extensibility and usability
- plymouth - Pretty boot screens
- yazi - Blazing fast terminal file manager
- None for now!