Update panicwrap to pass through all interrupt signals

This commit is contained in:
Mitchell Hashimoto 2016-12-07 20:51:45 -05:00
parent 9ab7cab19e
commit 557375f2a2
No known key found for this signature in database
GPG Key ID: 744E147AA52F5B0A
2 changed files with 5 additions and 1 deletions

View File

@ -60,6 +60,7 @@ func realMain() int {
wrapConfig.Handler = panicHandler(logTempFile)
wrapConfig.Writer = io.MultiWriter(logTempFile, logWriter)
wrapConfig.Stdout = outW
wrapConfig.IgnoreSignals = interruptSignals
exitStatus, err := panicwrap.Wrap(&wrapConfig)
if err != nil {
fmt.Fprintf(os.Stderr, "Couldn't start Terraform: %s", err)

View File

@ -7,4 +7,7 @@ import (
"syscall"
)
var interruptSignals []os.Signal = []os.Signal{os.Interrupt, syscall.SIGTERM}
var interruptSignals []os.Signal = []os.Signal{
os.Interrupt,
syscall.SIGTERM,
}