1
0
mirror of https://github.com/rancher/os.git synced 2025-09-02 07:15:41 +00:00

Simplify the network setup

Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
Sven Dowideit
2017-04-19 12:47:44 +00:00
parent 9e0302fd85
commit e05f30c4fc
2 changed files with 3 additions and 21 deletions

View File

@@ -59,19 +59,14 @@ func Main() {
log.Errorf("Failed to run udev settle: %v", err)
}
cfg := rancherConfig.LoadConfig()
log.Debugf("init: SaveCloudConfig(pre ApplyNetworkConfig): %#v", cfg.Rancher.Network)
network.ApplyNetworkConfig(cfg)
if err := SaveCloudConfig(); err != nil {
if err := saveCloudConfig(); err != nil {
log.Errorf("Failed to save cloud-config: %v", err)
}
}
func SaveCloudConfig() error {
func saveCloudConfig() error {
log.Debugf("SaveCloudConfig")
// TODO: can't run these here, but it needs to be triggered from here :()
cfg := rancherConfig.LoadConfig()
log.Debugf("init: SaveCloudConfig(pre ApplyNetworkConfig): %#v", cfg.Rancher.Network)
network.ApplyNetworkConfig(cfg)