move enforceTor logic to service modules
This enables tor support for services without using secure-node.nix
This commit is contained in:
@@ -38,12 +38,12 @@ in {
|
||||
};
|
||||
proxy = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = null;
|
||||
default = if cfg.enforceTor then config.services.tor.client.socksListenAddress else null;
|
||||
description = "Set a socks proxy to use to connect to Tor nodes (or for all connections if *always-use-proxy* is set)";
|
||||
};
|
||||
always-use-proxy = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
default = cfg.enforceTor;
|
||||
description = ''
|
||||
Always use the *proxy*, even to connect to normal IP addresses (you can still connect to Unix domain sockets manually). This also disables all DNS lookups, to avoid leaking information.
|
||||
'';
|
||||
|
||||
Reference in New Issue
Block a user