add tproxy/tun autostart option

This commit is contained in:
FUFSoB committed 2026-04-13 16:58:33 +05:00
1 parent aac8e8d17d
commit b8496a5737
5 files changed
+182 -2

No files matched your search

+24
View File
@@ -491,6 +491,18 @@ in
tun = {
enable = mkEnableOption "TUN mode service (opt-in, mutually exclusive with proxy-suite-tproxy)";
autostart = mkOption {
type = types.bool;
default = false;
description = ''
Whether to start proxy-suite-tun automatically during boot by
attaching it to multi-user.target.
Only relevant when singBox.tun.enable = true.
Cannot be enabled together with singBox.tproxy.autostart.
'';
example = true;
};
interface = mkOption {
type = types.str;
default = "singtun0";
@@ -525,6 +537,18 @@ in
tproxy = {
enable = mkEnableOption "TProxy mode service (opt-in, transparent proxy via nftables)";
autostart = mkOption {
type = types.bool;
default = false;
description = ''
Whether to start proxy-suite-tproxy automatically during boot by
attaching it to multi-user.target.
Only relevant when singBox.tproxy.enable = true.
Cannot be enabled together with singBox.tun.autostart.
'';
example = true;
};
localSubnets = mkOption {
type = types.listOf types.str;
default = [ "192.168.0.0/16" ];