Add tun stack option
This commit is contained in:
@@ -21,6 +21,7 @@ type ConfigOptions struct {
|
|||||||
MixedPort uint16 `json:"mixed-port"`
|
MixedPort uint16 `json:"mixed-port"`
|
||||||
LocalDnsPort uint16 `json:"local-dns-port"`
|
LocalDnsPort uint16 `json:"local-dns-port"`
|
||||||
MTU uint32 `json:"mtu"`
|
MTU uint32 `json:"mtu"`
|
||||||
|
TUNStack string `json:"tun-stack"`
|
||||||
ConnectionTestUrl string `json:"connection-test-url"`
|
ConnectionTestUrl string `json:"connection-test-url"`
|
||||||
URLTestInterval option.Duration `json:"url-test-interval"`
|
URLTestInterval option.Duration `json:"url-test-interval"`
|
||||||
EnableClashApi bool `json:"enable-clash-api"`
|
EnableClashApi bool `json:"enable-clash-api"`
|
||||||
@@ -129,6 +130,7 @@ func BuildConfig(configOpt ConfigOptions, input option.Options) option.Options {
|
|||||||
Type: C.TypeTun,
|
Type: C.TypeTun,
|
||||||
Tag: "tun-in",
|
Tag: "tun-in",
|
||||||
TunOptions: option.TunInboundOptions{
|
TunOptions: option.TunInboundOptions{
|
||||||
|
Stack: configOpt.TUNStack,
|
||||||
MTU: configOpt.MTU,
|
MTU: configOpt.MTU,
|
||||||
AutoRoute: true,
|
AutoRoute: true,
|
||||||
StrictRoute: true,
|
StrictRoute: true,
|
||||||
|
|||||||
Reference in New Issue
Block a user