MCPcopy Create free account
hub / github.com/containers/common / getDefultCNIConfigDir

Function getDefultCNIConfigDir

libnetwork/network/interface.go:182–192  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

180}
181
182func getDefultCNIConfigDir() (string, error) {
183 if !unshare.IsRootless() {
184 return cniConfigDir, nil
185 }
186
187 configHome, err := homedir.GetConfigHome()
188 if err != nil {
189 return "", err
190 }
191 return filepath.Join(configHome, cniConfigDirRootless), nil
192}
193
194// getDefaultNetavarkConfigDir return the netavark config dir. For rootful it will
195// use "/etc/containers/networks" and for rootless "$graphroot/networks". We cannot

Callers 1

getCniInterfaceFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…