clanModules/machine-id: fix value

This commit is contained in:
vdbe
2025-03-02 10:41:35 +01:00
parent f0e5b14846
commit f06b756b97

View File

@@ -10,18 +10,18 @@ let
in in
{ {
config = lib.mkMerge [ config = lib.mkMerge [
(lib.mkIf ((var.machineId.value or null) != null) { (lib.mkIf ((var.value or null) != null) {
assertions = [ assertions = [
{ {
assertion = lib.stringLength var.machineId.value == 32; assertion = lib.stringLength var.value == 32;
message = "machineId must be exactly 32 characters long."; message = "machineId must be exactly 32 characters long.";
} }
]; ];
boot.kernelParams = [ boot.kernelParams = [
''systemd.machine_id=${var.machineId.value}'' ''systemd.machine_id=${var.value}''
]; ];
environment.etc."machine-id" = { environment.etc."machine-id" = {
text = var.machineId.value; text = var.value;
}; };
}) })
{ {