move clanName into nixos machine configuration

This commit is contained in:
Jörg Thalheim
2023-12-08 16:02:54 +01:00
committed by Mic92
parent 08871258bb
commit 26c6954db0
5 changed files with 13 additions and 25 deletions

View File

@@ -20,6 +20,12 @@
default = self.lib.jsonschema.parseOptions options.clan;
};
options.clanCore = {
clanName = lib.mkOption {
type = lib.types.str;
description = ''
the name of the clan
'';
};
clanDir = lib.mkOption {
type = lib.types.either lib.types.path lib.types.str;
description = ''

View File

@@ -52,8 +52,9 @@ in
system.clan.vm = {
# for clan vm inspect
config = {
inherit (config.clan.virtualisation) cores graphics;
clan_name = config.clanCore.clanName;
memory_size = config.clan.virtualisation.memorySize;
inherit (config.clan.virtualisation) cores graphics;
};
# for clan vm create
create = pkgs.writeText "vm.json" (builtins.toJSON {