Documentation
¶
Overview ¶
Package command implements a Pilot notification plugin that executes a user-provided script from /config/scripts/ on each event. The event payload is passed as JSON on stdin and key fields are set as environment variables.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ScriptsDir = "/config/scripts" //nolint:gochecknoglobals // injectable for tests
ScriptsDir is the directory from which scripts are resolved. Package-level var so tests can override it.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
ScriptName string `json:"script_name"`
Timeout int `json:"timeout,omitempty"` // seconds; default 30
}
Config holds the user-supplied settings for a command notifier.
Click to show internal directories.
Click to hide internal directories.