Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitConfig ¶
InitConfig create default config file in given path
Types ¶
type Args ¶
type Args struct { Command string `arg:"-c"` Recipients []string `arg:"-r"` Comment string `help:"Comment for email Message"` ValidExitCode []int `arg:"--valid-exitcodes" help:"Valid exitcodes for executed command"` Daemon bool `arg:"-d" help:"Daemonize process after start. DONT implemented"` DontDuplicate bool `arg:"--dont-duplicate" help:"Not run process when process with same key already run"` DontDuplicateKey string `arg:"--dont-duplicate-key" help:"Default: --command value"` Retry int `help:"Retry run N times on fail."` Timeout int `arg:"-t" help:"Kill process after N seconds. Default: 0"` RetrySleep int `arg:"--retry-sleep" help:"Sleep between retries (seconds)"` Tty bool `help:"Allocate pseudo-terminal for executed command"` Config string `help:"Path to config file."` InitConfig bool `help:"Write default config to --config path and exit"` }
Args cli args structure
type ErrLockAlreadyAquired ¶
type ErrLockAlreadyAquired struct {
// contains filtered or unexported fields
}
ErrLockAlreadyAquired : error, that returned then lock already acquired by another process
func (*ErrLockAlreadyAquired) Error ¶
func (e *ErrLockAlreadyAquired) Error() string
type ErrLockAquireFailed ¶
type ErrLockAquireFailed struct {
// contains filtered or unexported fields
}
ErrLockAquireFailed : error, that returned then lock acquire failed with error
func (*ErrLockAquireFailed) Error ¶
func (e *ErrLockAquireFailed) Error() string
type ErrLockNotOwned ¶
type ErrLockNotOwned struct{}
ErrLockNotOwned : error, that returned then you trying release not owned lock
func (*ErrLockNotOwned) Error ¶
func (e *ErrLockNotOwned) Error() string
type ErrLockReleaseFailed ¶
type ErrLockReleaseFailed struct {
// contains filtered or unexported fields
}
ErrLockAquireFailed : error, that returned then lock acquire failed with error
func (*ErrLockReleaseFailed) Error ¶
func (e *ErrLockReleaseFailed) Error() string
type Lock ¶
type Lock struct { Key string // contains filtered or unexported fields }
Lock manage lock file
Click to show internal directories.
Click to hide internal directories.