On 9/8/25 05:12, Alyssa Ross wrote: > Demi Marie Obenour writes: > >> systemd-sysupdate expects one to exist and it's a good idea to have one >> anyway. Some third-party dependencies might check for it. >> >> Signed-off-by: Demi Marie Obenour >> --- >> host/rootfs/Makefile | 1 + >> host/rootfs/etc/os-release | 12 ++++++++++++ >> host/rootfs/etc/os-release.license | 2 ++ >> img/app/Makefile | 1 + >> img/app/etc/os-release | 12 ++++++++++++ >> img/app/etc/os-release.license | 2 ++ >> vm/sys/net/Makefile | 1 + >> vm/sys/net/etc/os-release | 12 ++++++++++++ >> vm/sys/net/etc/os-release.license | 2 ++ >> 9 files changed, 45 insertions(+) >> > > In general, I wouldn't want most software to be making decisions on > /etc/os-release. (systemd-sysupdate is a special case here in having a > good reason to do it.) Maybe in img/app we need it for compatibility > with arbitrary stuff, but if anything in vm/sys/net is looking at > os-release I'd rather it crash and I find out about it so I could fix > it. I don't think it would crash, though, just fall back to other behavior (which might not be desirable). > If we do have an /etc/os-release file on the host though, would be great > if we could re-use it when building the UKI in release/live. > (dump.erofs is probably useful here.) That should be doable. >> diff --git a/host/rootfs/Makefile b/host/rootfs/Makefile >> index 6cdbac201257faedb70344bcfd5cf9d4fd25b507..4faaccab8cb01d57ef7c48c01eb6fb1326cea4a0 100644 >> --- a/host/rootfs/Makefile >> +++ b/host/rootfs/Makefile >> @@ -17,6 +17,7 @@ FILES = \ >> etc/mdev/listen \ >> etc/mdev/net/add \ >> etc/mdev/wait \ >> + etc/os-release \ >> etc/parse-devname \ >> etc/passwd \ >> etc/s6-linux-init/env/WAYLAND_DISPLAY \ >> diff --git a/host/rootfs/etc/os-release b/host/rootfs/etc/os-release >> new file mode 100644 >> index 0000000000000000000000000000000000000000..536183411aa94b727f045c4623c29d66503738be >> --- /dev/null >> +++ b/host/rootfs/etc/os-release >> @@ -0,0 +1,12 @@ >> +NAME="Spectrum OS" > > NAME="Spectrum". There's no "OS" is the name. > >> +ID="spectrum" >> +PRETTY_NAME="Spectrum OS 0.0.0-alpha0" >> +VERSION="0.0.0-alpha0" >> +VERSION_ID="0" >> +IMAGE_ID="Spectrum-OS-Host" > > The documentation for this field says "A lower-case string". > >> +IMAGE_VERSION="0" > > Given we don't have a versioning scheme, why fill in these optional > fields? > >> +RELEASE_TYPE="development" > > Surely stable (the default) would be more accurate, given the examples > for that include OpenSUSE Tumbleweed and Arch Linux, which have a > similar rolling release model to what Spectrum will have? We don't have > a distinction between development and release builds, and I don't expect > us to. It's development because Spectrum OS is not yet stable. Once Spectrum OS goes live it should obviously be changed. >> +HOME_URL="https://www.spectrum-os.org/" >> +VENDOR_URL="https://www.spectrum-os.org/" > > "The VENDOR_NAME= field should be set if this one is" Fair. >> +ANSI_COLOR="1;34" >> +DEFAULT_HOSTNAME="spectrum-host" > > What do we expect this to do? Causes systemd (if used) to set the hostname of the host. -- Sincerely, Demi Marie Obenour (she/her/hers)