container/init: do not suspend output
All checks were successful
Test / Create distribution (push) Successful in 25s
Test / Sandbox (push) Successful in 39s
Test / Sandbox (race detector) (push) Successful in 39s
Test / Hakurei (push) Successful in 42s
Test / Hakurei (race detector) (push) Successful in 43s
Test / Hpkg (push) Successful in 41s
Test / Flake checks (push) Successful in 1m20s

Init is not very talkative after process start even when verbose. Suspending output here is pointless and does more harm than good.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2025-10-23 08:11:00 +09:00
parent 57231d4acf
commit 0fd357e7f6
2 changed files with 1 additions and 118 deletions

View File

@@ -341,7 +341,6 @@ func initEntrypoint(k syscallDispatcher, msg message.Msg) {
if err := k.start(cmd); err != nil {
k.fatalf(msg, "%v", err)
}
msg.Suspend()
if err := closeSetup(); err != nil {
k.printf(msg, "cannot close setup pipe: %v", err)
@@ -401,7 +400,6 @@ func initEntrypoint(k syscallDispatcher, msg message.Msg) {
select {
case s := <-sig:
if s == CancelSignal && params.ForwardCancel && cmd.Process != nil {
msg.Resume()
msg.Verbose("forwarding context cancellation")
if err := k.signal(cmd, os.Interrupt); err != nil {
k.printf(msg, "cannot forward cancellation: %v", err)
@@ -417,11 +415,7 @@ func initEntrypoint(k syscallDispatcher, msg message.Msg) {
continue
}
if msg.Resume() {
msg.Verbosef("%s after process start", s.String())
} else {
msg.Verbosef("got %s", s.String())
}
msg.Verbosef("got %s", s.String())
msg.BeforeExit()
k.exit(0)
@@ -433,9 +427,6 @@ func initEntrypoint(k syscallDispatcher, msg message.Msg) {
}
if w.wpid == cmd.Process.Pid {
// initial process exited, output is most likely available again
msg.Resume()
switch {
case w.wstatus.Exited():
r = w.wstatus.ExitStatus()