From 82aea8268f13e6579543707f27e4cc6e5da5e1b3 Mon Sep 17 00:00:00 2001 From: sora-ext Date: Tue, 12 May 2026 17:46:23 +0200 Subject: [PATCH] Update modules/shared/syscfg/default.nix --- modules/shared/syscfg/default.nix | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/modules/shared/syscfg/default.nix b/modules/shared/syscfg/default.nix index bde6a66..6a58252 100644 --- a/modules/shared/syscfg/default.nix +++ b/modules/shared/syscfg/default.nix @@ -105,14 +105,32 @@ let # }; default = (lib.evalModules { modules =[ { freeformType = with lib.types; attrsOf anything; } ../colors ];}).config.colorScheme ; }; + loadedContainers = lib.mkOption { + readOnly = true; + type = lib.types.attrsOf (lib.types.submodule ({ name, ... }: { + options = { + name = lib.mkOption {type = lib.types.str; default = name;}; + sops = lib.mkOption {type = lib.types.bool; default = false;}; + db = lib.mkOption {type = lib.types.bool; default = false;}; + + paths = lib.mkOption {type = lib.types.listOf lib.types.attrs; default = [ ];}; + containers = lib.mkOption {type = lib.types.attrsOf lib.types.attrs; default = { };}; + cron = lib.mkOption {type = lib.types.listOf lib.types.str; default = [ ];}; + + setup = { + trigger = lib.mkOption {type = lib.types.str; default = "";}; + script = lib.mkOption {type = lib.types.nullOr lib.types.package; default = null;}; + envFile = lib.mkOption {type = lib.types.nullOr lib.types.str; default = null;}; + }; + }; + })); + + }; containers = mkOption { type = types.attrsOf (types.submodule { options = { - enable = mkOption { type = types.bool;default = false; }; - db = mkOption { type = types.bool;default = false; }; - sops = mkOption { type = types.bool;default = false; }; - ip = mkOption { type = types.nullOr types.str; default = null;}; subdomain = mkOption { type = types.nullOr types.str; default=null;}; + subpath = mkOption { type = types.nullOr types.str; default=null;}; port = mkOption { type = types.nullOr types.port; default = null; }; extra = mkOption { type = types.attrs; default = {}; }; };