1
0
mirror of https://github.com/rancher/os.git synced 2025-09-01 23:04:41 +00:00

Add the recovery console to the boot menu

Signed-off-by: Sven Dowideit <SvenDowideit@home.org.au>
This commit is contained in:
Sven Dowideit
2017-07-13 21:47:44 +10:00
parent c94a683b87
commit 553fed3eea
4 changed files with 13 additions and 8 deletions

View File

@@ -11,7 +11,6 @@ import (
"strings"
"syscall"
"github.com/SvenDowideit/cpuid"
"github.com/codegangsta/cli"
"github.com/rancher/os/cmd/cloudinitexecute"
"github.com/rancher/os/config"
@@ -154,7 +153,6 @@ func generateRespawnConf(cmdline, user string, sshd bool) string {
respawnConf.WriteString(gettyCmd)
if strings.Contains(cmdline, fmt.Sprintf("rancher.autologin=%s", tty)) {
respawnConf.WriteString(fmt.Sprintf(" -n -l /usr/bin/autologin -o %s:tty%d", user, i))
//respawnConf.WriteString(fmt.Sprintf(" --autologin %s", user))
}
respawnConf.WriteString(fmt.Sprintf(" --noclear %s linux\n", tty))
}
@@ -166,9 +164,7 @@ func generateRespawnConf(cmdline, user string, sshd bool) string {
respawnConf.WriteString(gettyCmd)
if strings.Contains(cmdline, fmt.Sprintf("rancher.autologin=%s", tty)) {
//respawnConf.WriteString(fmt.Sprintf(" -n -l /usr/bin/autologin -o rancher"))
respawnConf.WriteString(fmt.Sprintf(" -n -l /usr/bin/autologin -o %s:%s", user, tty))
//respawnConf.WriteString(fmt.Sprintf(" --autologin %s", user))
}
respawnConf.WriteString(fmt.Sprintf(" %s\n", tty))
}