File config.dae of Package dae

###############################################################################
# Only the most basic configuration is provided here, if you want a better    # 
# experience you need to write the configuration file according to your needs.#
# For more details, please check                                              #
# https://github.com/daeuniverse/dae/blob/main/example.dae                    #
# https://github.com/daeuniverse/dae/tree/main/docs                           #
# https://github.com/daeuniverse/dae/discussions/81                           #
###############################################################################

include {
    config.d/*.dae
}

global {
    tproxy_port: 12345

    # Log level: error, warn, info, debug, trace
    log_level: info

    # Disable waiting for network before pulling subscriptions.
    disable_waiting_network: false
    
    # The LAN interface to bind. Use it if you want to proxy LAN.
    # Multiple interfaces split by ",".
    #lan_interface: virbr0

    # The WAN interface to bind. Use it if you want to proxy localhost.
    # Multiple interfaces split by ",". Use "auto" to auto detect.
    wan_interface: auto

    auto_config_kernel_parameter: true

    ##### Node connectivity check.
    
    tcp_check_url: 'http://cp.cloudflare.com'
    udp_check_dns: 'dns.google.com:53'

    check_interval: 30s
    check_tolerance: 50ms

    ##### Connecting options.

    dial_mode: domain++

    # Allow insecure TLS certificates. It is not recommended to turn it on unless you have to.
    allow_insecure: false

    # Timeout to waiting for first data sending for sniffing. It is always 0 if dial_mode is ip. Set it higher is useful
    # in high latency LAN network.
    sniffing_timeout: 100ms
}

# Subscriptions defined here will be resolved as nodes and merged as a part of the global node pool.
# Support to give the subscription a tag, and filter nodes from a given subscription in the group section.
subscription {
    # # Add your subscription links here.
    # my_sub: 'https://www.example.com/subscription/link'
    # another_sub: 'https://example.com/another_sub'
    # 'https://example.com/no_tag_link'
    # 'file://relative/path/to/mysub.sub' # Put subscription content in /etc/dae/relative/path/to/mysub.sub
}

# Nodes defined here will be merged as a part of the global node pool.
node {
    # # Add your node links here.
    # # Support socks5, http, https, ss, ssr, vmess, vless, trojan, tuic, juicity, etc.
    # # Full support list: https://github.com/daeuniverse/dae/blob/main/docs/en/proxy-protocols.md
    # 'socks5://localhost:1080'
    # mylink: 'ss://LINK'
    # node1: 'vmess://LINK'
    # node2: 'vless://LINK'
    # chains: 'tuic://LINK -> vmess://LINK'
}

# See https://github.com/daeuniverse/dae/blob/main/docs/en/configuration/dns.md for full examples.
dns {
    # For example, if ipversion_prefer is 4 and the domain name has both type A and type AAAA records, the dae will only
    # respond to type A queries and response empty answer to type AAAA queries.
    #ipversion_prefer: 4
    upstream {
        alidns: 'udp://223.5.5.5:53'
        googledns: 'tcp://8.8.8.8:53'
    }
    routing {
        request {
            qname(
                geosite:cn
            ) -> alidns
            fallback: googledns
        }
    }
}

group {
    proxy {
        policy: min_avg10
    }
}

routing {
    pname(dnsmasq, systemd-resolved) && l4proto(udp) && dport(53) -> must_direct
    dip(224.0.0.0/3, 'ff00::/8') -> direct
    
    # Dircet Application
    pname(
        NetworkManager
    ) -> direct

    # Proxy Application
    pname(
        git,
        curl
    ) -> proxy

    # Dircet IP
    dip(
        geoip:private,
        geoip:cn
    ) -> direct

    # Dircet Domain
    domain(
        geosite:cn,
        geosite:category-scholar-cn
    ) -> direct

    fallback: proxy
}
openSUSE Build Service is sponsored by