Documentation ¶
Overview ¶
Package daemon provides facilities for daemon operation.
Index ¶
Constants ¶
const ( // RecommendedDialTimeout is the recommended timeout to use when connecting // to the daemon over IPC. RecommendedDialTimeout = 1 * time.Second )
const RegistrationSupported = false
RegistrationSupported indicates whether or not daemon registration is supported on this platform.
Variables ¶
This section is empty.
Functions ¶
func DialTimeout ¶
DialTimeout attempts to establish a daemon IPC connection, timing out after the specified duration.
func NewListener ¶
NewListener creates a new daemon IPC listener.
func RegisteredStart ¶
RegisteredStart potentially handles daemon start operations if the daemon is registered for automatic start with the system. It returns false if the start operation was not handled and should be handled by the normal start command.
func RegisteredStop ¶
RegisteredStop potentially handles stop start operations if the daemon is registered for automatic start with the system. It returns false if the stop operation was not handled and should be handled by the normal stop command.
func Unregister ¶
func Unregister() error
Unregister performs automatic daemon startup de-registration.
Types ¶
type Lock ¶
type Lock struct {
// contains filtered or unexported fields
}
Lock represents a daemon lock instance.
func AcquireLock ¶
AcquireLock attempts to acquire the daemon lock. It is the only way to acquire a Lock instance.