1
0
mirror of https://github.com/rancher/os.git synced 2025-09-01 14:48:55 +00:00

Add debug to upgrade to track down why the global.cfg isn't persisting

Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
Sven Dowideit
2017-04-21 15:16:51 +00:00
parent 56ac7f1f87
commit a21c414ce1
3 changed files with 53 additions and 3 deletions

View File

@@ -939,6 +939,7 @@ func upgradeBootloader(device, baseName, bootDir, diskType string) error {
for _, line := range lines {
line = strings.TrimSpace(line)
if strings.HasPrefix(line, "APPEND") {
log.Errorf("write new (%s) %s", filepath.Join(baseName, bootDir, "global.cfg"), err)
// TODO: need to append any extra's the user specified
ioutil.WriteFile(filepath.Join(baseName, bootDir, "global.cfg"), []byte(cfg), 0644)
break