forked from docker/cli
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request docker#4599 from laurazard/plugin-signal-handling
cli-plugins: terminate plugin when CLI exits
- Loading branch information
Showing
7 changed files
with
123 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
//go:build unix | ||
// +build unix | ||
|
||
package signals | ||
|
||
import ( | ||
"os" | ||
|
||
"golang.org/x/sys/unix" | ||
) | ||
|
||
// TerminationSignals represents the list of signals we | ||
// want to special-case handle, on this platform. | ||
var TerminationSignals = []os.Signal{unix.SIGTERM, unix.SIGINT} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package signals | ||
|
||
import "os" | ||
|
||
// TerminationSignals represents the list of signals we | ||
// want to special-case handle, on this platform. | ||
var TerminationSignals = []os.Signal{os.Interrupt} |