nix-config/modules/meta.nix

29 lines
515 B
Nix
Raw Normal View History

2023-08-26 14:01:58 +02:00
{
config,
lib,
...
}: let
inherit
(lib)
mdDoc
mkOption
types
;
in {
options.node = {
name = mkOption {
description = mdDoc "A unique name for this node (host) in the repository. Defines the default hostname, but this can be overwritten.";
type = types.str;
};
secretsDir = mkOption {
description = mdDoc "Path to the secrets directory for this node.";
type = types.path;
};
};
config = {
networking.hostName = config.node.name;
};
}