nixos/release.nix: remove warning about missing state version for images

This commit is contained in:
Jörg Thalheim 2023-05-15 10:38:56 +02:00 committed by Jörg Thalheim
parent c9956c110e
commit 3a5ff9a68c

View File

@ -44,10 +44,13 @@ let
pkgs = import ./.. { system = "x86_64-linux"; };
versionModule =
{ system.nixos.versionSuffix = versionSuffix;
system.nixos.revision = nixpkgs.rev or nixpkgs.shortRev;
};
versionModule = { config, ... }: {
system.nixos.versionSuffix = versionSuffix;
system.nixos.revision = nixpkgs.rev or nixpkgs.shortRev;
# At creation time we do not have state yet, so just default to latest.
system.stateVersion = config.system.nixos.version;
};
makeModules = module: rest: [ configuration versionModule module rest ];