Handle SIGPIPE to prevent machine stuck in Starting state

Fixes: #26949
Signed-off-by: Jiri Dostal <jdostal@redhat.com>
This commit is contained in:
Jiri Dostal
2025-09-01 15:16:07 +02:00
committed by openshift-cherrypick-robot
parent 696b884e76
commit 1751612f33

View File

@ -483,7 +483,7 @@ func Start(mc *vmconfigs.MachineConfig, mp vmconfigs.VMProvider, dirs *machineDe
// if the machine cannot continue starting due to a signal, ensure the state
// reflects the machine is no longer starting
signalChan := make(chan os.Signal, 1)
signal.Notify(signalChan, os.Interrupt, syscall.SIGTERM)
signal.Notify(signalChan, os.Interrupt, syscall.SIGTERM, syscall.SIGPIPE)
go func() {
sig, ok := <-signalChan
if ok {