summaryrefslogtreecommitdiffstats
path: root/krebs/4lib
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2016-10-13 21:49:04 +0200
committertv <tv@krebsco.de>2016-10-13 22:11:31 +0200
commit7c91a1954992db9fa06619753faa3a193a196040 (patch)
tree80ff8db53afcccb64ccccbfc361f5addbdc9ca30 /krebs/4lib
parent1a5f52234e4a21f21eb198ed0bffeb7dc2168bdf (diff)
lib: don't define defaults that require config
Diffstat (limited to 'krebs/4lib')
-rw-r--r--krebs/4lib/default.nix1
-rw-r--r--krebs/4lib/types.nix13
2 files changed, 1 insertions, 13 deletions
diff --git a/krebs/4lib/default.nix b/krebs/4lib/default.nix
index 3f224edd..c40b9a86 100644
--- a/krebs/4lib/default.nix
+++ b/krebs/4lib/default.nix
@@ -19,7 +19,6 @@ let out = lib // rec {
]));
types = import ./types.nix {
- inherit config;
lib = lib // { inherit genid optionalTrace; };
};
diff --git a/krebs/4lib/types.nix b/krebs/4lib/types.nix
index 02ca2b8d..8d6ace2e 100644
--- a/krebs/4lib/types.nix
+++ b/krebs/4lib/types.nix
@@ -1,14 +1,9 @@
-{ config, lib, ... }:
+{ lib, ... }:
with builtins;
with lib;
with types;
-let
- # Inherited attributes are used in submodules that have their own `config`.
- inherit (config.krebs) build users;
-in
-
types // rec {
host = submodule ({ config, ... }: {
@@ -27,7 +22,6 @@ types // rec {
owner = mkOption {
type = user;
- default = users.krebs;
};
extraZones = mkOption {
@@ -49,10 +43,6 @@ types // rec {
ssh.pubkey = mkOption {
type = nullOr ssh-pubkey;
default = null;
- apply = x:
- optionalTrace (x == null && config.owner.name == build.user.name)
- "The option `krebs.hosts.${config.name}.ssh.pubkey' is unused."
- x;
};
ssh.privkey = mkOption {
type = nullOr ssh-privkey;
@@ -187,7 +177,6 @@ types // rec {
};
owner = mkOption {
type = user;
- default = users.root;
};
group-name = mkOption {
type = str;