add socks proxy in ks
This commit is contained in:
parent
ad97f8329a
commit
ce3aadf4f0
2 changed files with 27 additions and 0 deletions
26
os/3proxy.nix
Normal file
26
os/3proxy.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{
|
||||
services._3proxy = {
|
||||
enable = true;
|
||||
services = [
|
||||
{
|
||||
type = "socks";
|
||||
auth = [ "strong" ];
|
||||
acl = [ {
|
||||
rule = "allow";
|
||||
users = [ "user1" ];
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
usersFile = "/etc/3proxy.passwd";
|
||||
};
|
||||
|
||||
environment.etc = {
|
||||
"3proxy.passwd".text = ''
|
||||
user1:CR:$1$TqAb0wvc$e.O2GhdhXaMYSxNdNBmzh/
|
||||
'';
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 1080 ];
|
||||
networking.firewall.allowedUDPPorts = [ 1080 ];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue