Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:15
google-guest-agent.29776
dont_overwrite_ifcfg.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File dont_overwrite_ifcfg.patch of Package google-guest-agent.29776
diff -Nru guest-agent-20211019.00.orig/google_guest_agent/addresses.go guest-agent-20211019.00/google_guest_agent/addresses.go --- guest-agent-20211019.00.orig/google_guest_agent/addresses.go 2021-10-20 00:09:13.000000000 +0200 +++ guest-agent-20211019.00/google_guest_agent/addresses.go 2021-10-22 11:32:04.447560133 +0200 @@ -558,7 +558,12 @@ logger.Debugf("write enabling ifcfg-%s config", iface) var ifcfg *os.File - ifcfg, err = os.Create("/etc/sysconfig/network/ifcfg-" + iface) + filename := "/etc/sysconfig/network/ifcfg-" + iface + _, err = os.Stat(filename) + if ! os.IsNotExist(err) { + return nil + } + ifcfg, err = os.Create(filename) if err != nil { return err }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor