mirror of
https://github.com/hashicorp/vault.git
synced 2026-06-09 00:33:28 -04:00
Properly handle sigint/hup
This commit is contained in:
parent
bb3a8d844a
commit
4268158c82
1 changed files with 1 additions and 2 deletions
|
|
@ -685,7 +685,6 @@ func MakeShutdownCh() chan struct{} {
|
|||
resultCh := make(chan struct{})
|
||||
|
||||
shutdownCh := make(chan os.Signal, 4)
|
||||
signal.Notify(shutdownCh, os.Interrupt, syscall.SIGINT)
|
||||
signal.Notify(shutdownCh, os.Interrupt, syscall.SIGTERM)
|
||||
go func() {
|
||||
for {
|
||||
|
|
@ -703,7 +702,7 @@ func MakeSighupCh() chan struct{} {
|
|||
resultCh := make(chan struct{})
|
||||
|
||||
signalCh := make(chan os.Signal, 4)
|
||||
signal.Notify(signalCh, os.Interrupt, syscall.SIGHUP)
|
||||
signal.Notify(signalCh, syscall.SIGHUP)
|
||||
go func() {
|
||||
for {
|
||||
<-signalCh
|
||||
|
|
|
|||
Loading…
Reference in a new issue