Merge pull request #648 from bergwolf/vmconsole

builtin-proxy: print guest console output to logger
This commit is contained in:
James O. D. Hunt 2018-08-28 14:46:10 +01:00 committed by GitHub
commit dcf3229b37
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -82,7 +82,10 @@ func (p *kataBuiltInProxy) watchConsole(proto, console string, logger *logrus.En
go func() {
scanner = bufio.NewScanner(conn)
for scanner.Scan() {
fmt.Printf("[SB-%s] vmconsole: %s\n", p.sandboxID, scanner.Text())
logger.WithFields(logrus.Fields{
"sandbox": p.sandboxID,
"vmconsole": scanner.Text(),
}).Debug("reading guest console")
}
if err := scanner.Err(); err != nil {