Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
Merge pull request #830 from keloyang/resolv
Browse files Browse the repository at this point in the history
network: Fix Could not create destination mount point: /etc/resolv.conf
  • Loading branch information
amshinde authored Sep 11, 2020
2 parents f8e934e + a48a062 commit e82e2f7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions network.go
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,11 @@ func setupDNS(dns []string) (err error) {
return nil
}

if _, err := os.Stat(guestDNSFile); err != nil && os.IsNotExist(err) {
agentLog.Errorf("%s is not exist in guest, dns service may be unavailable", guestDNSFile)
return nil
}

if err := os.MkdirAll(filepath.Dir(kataGuestSandboxDNSFile), 0700); err != nil {
return err
}
Expand Down

0 comments on commit e82e2f7

Please sign in to comment.