Documentation ¶
Index ¶
Constants ¶
View Source
const ( Ok = 0 Warning = 1 Critical = 2 Unknown = 3 Timeout = 124 NotExecutable = 126 NotFound = 127 )
Unified exit codes
Variables ¶
This section is empty.
Functions ¶
func FileExists ¶
Types ¶
type CommandArgs ¶
type CommandResult ¶
type CommandResult struct { Stdout string `json:"stdout"` RC int `json:"rc"` ExecutionUnixTimestampSec int64 `json:"execution_unix_timestamp_sec"` }
CommandResult to return the information
func RunCommand ¶
func RunCommand(ctx context.Context, commandArgs CommandArgs) (*CommandResult, error)
RunCommand in shell style with timeout on every platform
Click to show internal directories.
Click to hide internal directories.