Skip to content

Add support for multiple NixOS system profiles#541

Open
leguteape wants to merge 3 commits intonix-community:masterfrom
leguteape:master
Open

Add support for multiple NixOS system profiles#541
leguteape wants to merge 3 commits intonix-community:masterfrom
leguteape:master

Conversation

@leguteape
Copy link
Copy Markdown

Hey everyone. This PR attempts to add support for NixOS system profiles to lanzaboote. I had originally written this patch at around August of 2025 for personal use but the folks over at #135 have encouraged me to create a PR here.

Here's a list of the most important changes:

  • Get profile names from system-profiles/ while also being compatible with non-profiled systems
  • Since profile names can also have - characters, handle any stray -s so versions and profile names can be safely extracted
  • Add profile names to the .efi entries as well as in boot menus in a fashion consistent with systemd-boot
  • Update the unit and integration tests to accommodate the presence and absence of profiles

I must add that I didn't know any Rust and sorta hacked my way around when I made these changes, following compiler hints and warnings. So, the quality of the my modifications may not be the best. I would, hence, be welcoming of any suggestions aimed towards improving the quality of this patch.

P.S. Here's an image of what the boot menu looks like after my changes (profile names are inside square brackets):

image
  • Entry 1 belongs to the default profile, aka the system profile.
  • Entry 2 belongs to the Workstation profile
  • Entry 3 belongs to the Gamestation profile

@RaitoBezarius
Copy link
Copy Markdown
Member

@rv32ima can I let you do a first pass? Then ping me and I will do another pass so we can get that promptly merged.

@RaitoBezarius RaitoBezarius requested a review from nikstur January 21, 2026 17:02
@leguteape leguteape force-pushed the master branch 4 times, most recently from 25a3a2b to 484948c Compare February 9, 2026 06:16
- Make profile name available in bootmenu entries to aid identification
- Also add profile name to .efi files in `EFI/Linux`
- Handle cases where profile name is not specified by falling back to
`system-*-link`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants