Skip to content

Commit

Permalink
Add missing comment about fallback
Browse files Browse the repository at this point in the history
Signed-off-by: Itxaka <itxaka@kairos.io>
  • Loading branch information
Itxaka committed Oct 1, 2024
1 parent 3d4c198 commit 6e60699
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/utils/grub.go
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ func (g Grub) Install(target, rootDir, bootDir, grubConf, tty string, efi bool,
var model string
model, err = utils.OSRelease("KAIROS_MODEL", filepath.Join(cnst.ActiveDir, "etc/kairos-release"))
if err != nil {
// Fallback into os-release
model, err = utils.OSRelease("KAIROS_MODEL", filepath.Join(cnst.ActiveDir, "etc/os-release"))
if err != nil {
g.config.Logger.Warnf("Failed reading model info from %s and %s: %v", filepath.Join(cnst.ActiveDir, "etc/kairos-release"), filepath.Join(cnst.ActiveDir, "os/kairos-release"), err)
Expand Down

0 comments on commit 6e60699

Please sign in to comment.