From ef60a01f3fdfe61c4930a776f137d2b3d6cf7637 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Sat, 15 Feb 2020 23:35:51 +0100 Subject: [PATCH] netconfigd: continue if interfaces.json does not exist --- internal/netconfig/netconfig.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/internal/netconfig/netconfig.go b/internal/netconfig/netconfig.go index 643078a..a55f958 100644 --- a/internal/netconfig/netconfig.go +++ b/internal/netconfig/netconfig.go @@ -219,6 +219,9 @@ func LinkAddress(dir, ifname string) (net.IP, error) { func applyInterfaces(dir, root string) error { b, err := ioutil.ReadFile(filepath.Join(dir, "interfaces.json")) if err != nil { + if os.IsNotExist(err) { + return nil + } return err } var cfg InterfaceConfig