diff --git a/checks/backups/flake-module.nix b/checks/backups/flake-module.nix index 82f45ace..097327b3 100644 --- a/checks/backups/flake-module.nix +++ b/checks/backups/flake-module.nix @@ -14,7 +14,7 @@ let in { flake.nixosConfigurations = { inherit (clan.nixosConfigurations) test_backup_client; }; - flake.clanInternals = clan.clanInternals; + flake.clanInternals.machines = clan.clanInternals.machines; flake.nixosModules = { test_backup_server = { ... }: { imports = [ diff --git a/flake.nix b/flake.nix index a515d40c..cad84578 100644 --- a/flake.nix +++ b/flake.nix @@ -24,7 +24,7 @@ }; outputs = inputs @ { flake-parts, ... }: - flake-parts.lib.mkFlake { inherit inputs; } ({ ... }: { + flake-parts.lib.mkFlake { inherit inputs; } ({ lib, ... }: { systems = [ "x86_64-linux" "aarch64-linux" @@ -41,6 +41,22 @@ ./lib/flake-module.nix ./nixosModules/flake-module.nix + { + options.flake = flake-parts.lib.mkSubmoduleOptions { + clanInternals = lib.mkOption { + type = lib.types.submodule { + options = { + all-machines-json = lib.mkOption { + type = lib.types.attrsOf lib.types.str; + }; + machines = lib.mkOption { + type = lib.types.attrsOf (lib.types.attrsOf lib.types.unspecified); + }; + }; + }; + }; + }; + } ]; }); }