mirror of
https://github.com/daeuniverse/dae.git
synced 2024-12-23 01:14:46 +07:00
fix: running issue and no network on android (#264)
This commit is contained in:
parent
5360893c3d
commit
e466295096
@ -59,10 +59,6 @@ func tryUpdateSystemDnsElapse(k time.Duration) (err error) {
|
||||
|
||||
func tryUpdateSystemDns() (err error) {
|
||||
dnsConf := dnsReadConfig("/etc/resolv.conf")
|
||||
if len(dnsConf.servers) == 0 {
|
||||
err = fmt.Errorf("no valid dns server in /etc/resolv.conf")
|
||||
return err
|
||||
}
|
||||
systemDns = netip.AddrPort{}
|
||||
for _, s := range dnsConf.servers {
|
||||
ipPort := netip.MustParseAddrPort(s)
|
||||
|
@ -141,7 +141,10 @@ func (s *Dns) InitUpstreams() {
|
||||
for _, upstream := range s.upstream {
|
||||
wg.Add(1)
|
||||
go func(upstream *UpstreamResolver) {
|
||||
upstream.GetUpstream()
|
||||
_, err := upstream.GetUpstream()
|
||||
if err != nil {
|
||||
s.log.WithError(err).Debugln("Dns.GetUpstream")
|
||||
}
|
||||
wg.Done()
|
||||
}(upstream)
|
||||
}
|
||||
|
@ -213,7 +213,7 @@ func NewControlPlane(
|
||||
// Bind to WAN
|
||||
if len(global.WanInterface) > 0 {
|
||||
if err = core.setupSkPidMonitor(); err != nil {
|
||||
return nil, err
|
||||
log.WithError(err).Warnln("cgroup2 is not enabled; pname routing cannot be used")
|
||||
}
|
||||
for _, ifname := range global.WanInterface {
|
||||
if err = core.bindWan(ifname, global.AutoConfigKernelParameter); err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user