summaryrefslogtreecommitdiffstats
path: root/4lib/tv
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2015-07-23 02:00:23 +0200
committertv <tv@krebsco.de>2015-07-23 02:00:23 +0200
commit27fe9055334443370a86307ed08d51b2606f509d (patch)
treeb4c51ae628c80015430b90c3fd1d96d8fd33319a /4lib/tv
parent039f3193b75e78cc133409b69fb9784ce001ad57 (diff)
4 tv: tinc.config can access tinc.pubkey
Diffstat (limited to '4lib/tv')
-rw-r--r--4lib/tv/default.nix12
1 files changed, 6 insertions, 6 deletions
diff --git a/4lib/tv/default.nix b/4lib/tv/default.nix
index 5eb9ac4..092a962 100644
--- a/4lib/tv/default.nix
+++ b/4lib/tv/default.nix
@@ -97,22 +97,22 @@ builtins // lib // rec {
type = listOf hostname;
};
tinc = mkOption {
- type = submodule {
+ type = let net-config = config; in submodule ({ config, ... }: {
options = {
config = mkOption {
type = str;
apply = _: ''
- ${optionalString (config.via != null)
- (concatMapStringsSep "\n" (a: "Address = ${a}") config.via.addrs)}
- ${concatMapStringsSep "\n" (a: "Subnet = ${a}") config.addrs}
- ${config.tinc.pubkey}
+ ${optionalString (net-config.via != null)
+ (concatMapStringsSep "\n" (a: "Address = ${a}") net-config.via.addrs)}
+ ${concatMapStringsSep "\n" (a: "Subnet = ${a}") net-config.addrs}
+ ${config.pubkey}
'';
};
pubkey = mkOption {
type = str;
};
};
- };
+ });
};
};
});