nixos-servers/flake-parts/checks.nix

15 lines
497 B
Nix
Raw Normal View History

2024-03-02 12:58:17 +00:00
{ self, hostPkgs, machines, flake-utils, deploy-rs, ... }: flake-utils.lib.eachDefaultSystem (system: {
# Deploy-rs' flake checks seem broken for architectures different from the deployment machine.
# We skip these here.
2024-03-05 19:56:00 +00:00
checks = deploy-rs.lib.${system}.deployChecks (
hostPkgs.lib.attrsets.updateManyAttrsByPath [{
path = [ "nodes" ];
update = hostPkgs.lib.attrsets.filterAttrs (name: node:
2024-03-02 12:58:17 +00:00
machines.${name}.arch == system
2024-03-05 19:56:00 +00:00
);
}]
self.deploy
);
2024-03-02 12:58:17 +00:00
})