diff --git a/base.nix b/base.nix index a47e021..8e6cf6a 100644 --- a/base.nix +++ b/base.nix @@ -4,6 +4,7 @@ imports = [ ./users ./modules/snakeoil-certs.nix + ./modules/debug-locations.nix ]; networking.domain = "pvv.ntnu.no"; diff --git a/modules/debug-locations.nix b/modules/debug-locations.nix new file mode 100644 index 0000000..8e10c27 --- /dev/null +++ b/modules/debug-locations.nix @@ -0,0 +1,13 @@ +{ config, lib, ... }: +let + cfg = config.environment.debug-locations; +in +{ + options.environment.debug-locations = lib.mkOption { + description = "Paths and derivations to symlink in `/etc/debug`"; + type = with lib.types; attrsOf path; + default = { }; + }; + + config.environment.etc = lib.mapAttrs' (k: v: lib.nameValuePair "debug/${k}" { source = v; }) cfg; +}