Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 11 additions & 2 deletions pkg/daemon/daemon.go
Original file line number Diff line number Diff line change
Expand Up @@ -535,10 +535,19 @@ func ReexecuteForTargetRoot(target string) error {
if sourceOsVersion.IsLikeRHEL() && targetOsVersion.IsLikeRHEL() {
sourceMajor := sourceOsVersion.BaseVersionMajor()
targetMajor := targetOsVersion.BaseVersionMajor()
if sourceMajor == "9" && targetMajor == "8" {

// When container is newer than target, use target-compatible binary
switch {
case sourceMajor == "10" && targetMajor == "9":
sourceBinarySuffix = ".rhel9"
klog.Info("container is rhel10, target is rhel9")
case sourceMajor == "10" && targetMajor == "8":
sourceBinarySuffix = ".rhel8"
klog.Info("container is rhel10, target is rhel8")
case sourceMajor == "9" && targetMajor == "8":
sourceBinarySuffix = ".rhel8"
klog.Info("container is rhel9, target is rhel8")
} else {
default:
klog.Infof("using appropriate binary for source=rhel-%s target=rhel-%s", sourceMajor, targetMajor)
}
} else {
Expand Down
2 changes: 1 addition & 1 deletion pkg/daemon/update.go
Original file line number Diff line number Diff line change
Expand Up @@ -2288,7 +2288,7 @@ func (dn *Daemon) updateKubeConfigPermission() error {
// (/home/core/.ssh/authorized_keys.d/ignition) or the old SSH key path
// (/home/core/.ssh/authorized_keys)
func (dn *Daemon) useNewSSHKeyPath() bool {
return dn.os.IsEL9() || dn.os.IsFCOS() || dn.os.IsSCOS()
return dn.os.IsEL9() || dn.os.IsEL10() || dn.os.IsFCOS() || dn.os.IsSCOS()
}

// Update a given PasswdUser's SSHKey
Expand Down