···
corresponding attribute name.
example = literalExample ''
40
-
server = "tunnel.mdomain.com";
40
+
server = "tunnel.mdomain.com";
46
-
type = types.attrsOf (types.submodule (
52
-
description = "Domain or Subdomain of server running iodined";
53
-
example = "tunnel.mydomain.com";
46
+
type = types.attrsOf (
53
+
description = "Domain or Subdomain of server running iodined";
54
+
example = "tunnel.mydomain.com";
59
-
description = "DNS server to use as a intermediate relay to the iodined server";
60
-
example = "8.8.8.8";
60
+
description = "DNS server to use as a intermediate relay to the iodined server";
61
+
example = "8.8.8.8";
63
-
extraConfig = mkOption {
66
-
description = "Additional command line parameters";
67
-
example = "-l 192.168.1.10 -p 23";
64
+
extraConfig = mkOption {
67
+
description = "Additional command line parameters";
68
+
example = "-l 192.168.1.10 -p 23";
70
-
passwordFile = mkOption {
73
-
description = "File that contains password";
71
+
passwordFile = mkOption {
74
+
description = "File that contains password";
···
boot.kernelModules = [ "tun" ];
125
-
createIodineClientService = name: cfg:
127
-
description = "iodine client - ${name}";
128
-
after = [ "network.target" ];
129
-
wantedBy = [ "multi-user.target" ];
130
-
script = "exec ${pkgs.iodine}/bin/iodine -f -u ${iodinedUser} ${cfg.extraConfig} ${optionalString (cfg.passwordFile != "") "< \"${cfg.passwordFile}\""} ${cfg.relay} ${cfg.server}";
132
-
RestartSec = "30s";
133
-
Restart = "always";
128
+
createIodineClientService = name: cfg:
130
+
description = "iodine client - ${name}";
131
+
after = [ "network.target" ];
132
+
wantedBy = [ "multi-user.target" ];
133
+
script = "exec ${pkgs.iodine}/bin/iodine -f -u ${iodinedUser} ${cfg.extraConfig} ${optionalString (cfg.passwordFile != "") "< \"${cfg.passwordFile}\""} ${cfg.relay} ${cfg.server}";
135
+
RestartSec = "30s";
136
+
Restart = "always";
142
+
(name: value: nameValuePair "iodine-${name}" (createIodineClientService name value))
145
+
iodined = mkIf (cfg.server.enable) {
146
+
description = "iodine, ip over dns server daemon";
147
+
after = [ "network.target" ];
148
+
wantedBy = [ "multi-user.target" ];
149
+
script = "exec ${pkgs.iodine}/bin/iodined -f -u ${iodinedUser} ${cfg.server.extraConfig} ${optionalString (cfg.server.passwordFile != "") "< \"${cfg.server.passwordFile}\""} ${cfg.server.ip} ${cfg.server.domain}";
139
-
(name: value: nameValuePair "iodine-${name}" (createIodineClientService name value))
142
-
iodined = mkIf (cfg.server.enable) {
143
-
description = "iodine, ip over dns server daemon";
144
-
after = [ "network.target" ];
145
-
wantedBy = [ "multi-user.target" ];
146
-
script = "exec ${pkgs.iodine}/bin/iodined -f -u ${iodinedUser} ${cfg.server.extraConfig} ${optionalString (cfg.server.passwordFile != "") "< \"${cfg.server.passwordFile}\""} ${cfg.server.ip} ${cfg.server.domain}";
users.users.${iodinedUser} = {
uid = config.ids.uids.iodined;