feat: better handling of nixos version depending on the machine

This commit is contained in:
Luj 2023-04-08 22:55:19 +02:00
parent 1117ecff61
commit dce1df08e3
Signed by: luj
GPG key ID: 6FC74C847011FD83
5 changed files with 172 additions and 8 deletions

View file

@ -62,6 +62,13 @@
outputs = { self, nixpkgs, deploy-rs, ... }@inputs:
let
remotePatches = [
{
meta.description = "pkgs: fix buildbot";
url = "https://github.com/NixOS/nixpkgs/pull/142273.diff";
sha256 = "sha256-ZCDQ7SpGhH8JvAwWzdcyrc68RFEWHxxAj0M2+AvEzIg=";
}
];
lib = nixpkgs.lib.extend (import ./lib inputs);
machines_plats = lib.mapAttrsToList (name: value: value.arch) lib.luj.machines;
@ -80,7 +87,15 @@
})
(builtins.attrNames (builtins.readDir ./modules)));
nixosConfigurations = builtins.mapAttrs (name: value: (lib.mkMachine { host = name; host-config = value; modules = self.nixosModules; nixpkgs = inputs.nixos-apple-silicon.inputs.nixpkgs; system = lib.luj.machines.${name}.arch; })) (lib.importConfig ./machines);
nixosConfigurations = builtins.mapAttrs
(name: value: (lib.mkMachine {
host = name;
host-config = value;
modules = self.nixosModules;
nixpkgs = lib.luj.machines.${name}.nixpkgs_version;
system = lib.luj.machines.${name}.arch;
}))
(lib.importConfig ./machines);
deploy.nodes.lambda = {
hostname = "lambda.julienmalka.me";