mirror of
https://github.com/rancher/os.git
synced 2025-09-01 14:48:55 +00:00
Use the partial cfg for the initial network
and release the network device from dhcp if we're not using it Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
@@ -11,7 +11,6 @@ import (
|
||||
|
||||
func Main() {
|
||||
log.InitLogger()
|
||||
log.Infof("Running network")
|
||||
|
||||
cfg := config.LoadConfig()
|
||||
ApplyNetworkConfig(cfg)
|
||||
@@ -20,6 +19,7 @@ func Main() {
|
||||
}
|
||||
|
||||
func ApplyNetworkConfig(cfg *config.CloudConfig) {
|
||||
log.Infof("Apply Network Config")
|
||||
nameservers := cfg.Rancher.Network.DNS.Nameservers
|
||||
search := cfg.Rancher.Network.DNS.Search
|
||||
userSetDNS := len(nameservers) > 0 || len(search) > 0
|
||||
|
Reference in New Issue
Block a user