diff options
author | lassulus <lass@aidsballs.de> | 2015-07-23 02:26:42 +0200 |
---|---|---|
committer | lassulus <lass@aidsballs.de> | 2015-07-23 02:26:42 +0200 |
commit | 0db3f4ee695148b60238861384b86f0fdc880459 (patch) | |
tree | 8249b4e2713aeabdf4a9d1aeee4c38e1a527e487 /3modules/tv/retiolum.nix | |
parent | b590d9e21d8c99a91fd419c3e0bea949a9ac6849 (diff) | |
parent | 791a7e79977de76908ab9e33eb64cbd2b02da3ed (diff) |
Merge branch 'tv' into master
Diffstat (limited to '3modules/tv/retiolum.nix')
-rw-r--r-- | 3modules/tv/retiolum.nix | 29 |
1 files changed, 7 insertions, 22 deletions
diff --git a/3modules/tv/retiolum.nix b/3modules/tv/retiolum.nix index 8dc4197aa..ca1418c32 100644 --- a/3modules/tv/retiolum.nix +++ b/3modules/tv/retiolum.nix @@ -46,7 +46,6 @@ let description = '' The tinc network name. It is used to generate long host entries, - derive the name of the user account under which tincd runs, and name the TUN device. ''; }; @@ -106,20 +105,22 @@ let # and the private key. ExecStartPre = pkgs.writeScript "retiolum-init" '' #! /bin/sh - install -o ${user} -m 0400 ${cfg.privateKeyFile} /tmp/retiolum-rsa_key.priv + install -o ${user.name} -m 0400 ${cfg.privateKeyFile} /tmp/retiolum-rsa_key.priv ''; - ExecStart = "${tinc}/sbin/tincd -c ${confDir} -d 0 -U ${user} -D"; + ExecStart = "${tinc}/sbin/tincd -c ${confDir} -d 0 -U ${user.name} -D"; SyslogIdentifier = "retiolum"; }; }; - # TODO user.name = "retiolum" users.extraUsers = singleton { - name = user; - uid = 2961822815; # bin/genid retiolum-tinc + inherit (user) name uid; }; }; + user = { + name = "retiolum"; + uid = 301281149; # genid retiolum + }; tinc = cfg.tincPackage; hostsType = builtins.typeOf cfg.hosts; @@ -217,21 +218,5 @@ let chmod +x $out/tinc-up ''; - - - user = cfg.network + "-tinc"; - in out - - - -#let -# cfg = config.tv.retiolum; -# arg' = arg // { inherit cfg; }; -#in -# -#{ -# options.tv.retiolum = import ./options.nix arg'; -# config = lib.mkIf cfg.enable (import ./config.nix arg'); -#} |