Version: v0.11.4 Latest Latest

This package is not in the latest version of its module.

Go to latest
Published: Jan 15, 2019 License: Apache-2.0 Imports: 10 Imported by: 3




This section is empty.


View Source
var (

	// DockerLegacyMode is true if Docker legacy mode is enabled.
	DockerLegacyMode bool

	// Arch is the uname OS-Arch string.
	Arch = fmt.Sprintf(

	// SemVer is the semantic version.
	SemVer string

	// CommitSha7 is the short version of the commit hash from which
	// this program was built.
	CommitSha7 string

	// CommitSha32 is the long version of the commit hash from which
	// this program was built.
	CommitSha32 string

	// CommitTime is the commit timestamp of the commit from which
	// this program was built.
	CommitTime time.Time

	// BuildType is the build type of this binary.
	BuildType = "client+agent+controller"

	// Debug is whether or not the REXRAY_DEBUG environment variable is set
	// to a truthy value.
	Debug, _ = strconv.ParseBool(os.Getenv("REXRAY_DEBUG"))


func IsExitSignal added in v0.5.0

func IsExitSignal(s os.Signal) (bool, bool)

IsExitSignal returns a flag indicating whether a signal is SIGKILL, SIGHUP, SIGINT, SIGTERM, or SIGQUIT. The second return value is whether it is a graceful exit. This flag is true for SIGTERM, SIGHUP, SIGINT, and SIGQUIT.

func RegisterSignalHandler added in v0.5.0

func RegisterSignalHandler(f SignalHandlerFunc)

RegisterSignalHandler registers a SignalHandlerFunc.

func TrapSignals added in v0.5.0

func TrapSignals(ctx apitypes.Context)

TrapSignals tells the process to trap incoming process signals.


type SignalHandlerFunc added in v0.5.0

type SignalHandlerFunc func(ctx apitypes.Context, s os.Signal)

SignalHandlerFunc is a function that can be registered with `core.RegisterSignalHandler` to receive a callback when the process receives a signal.


Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL