Documentation ¶
Index ¶
Constants ¶
View Source
const ( // DefaultHooksDir Default directory containing hooks config files DefaultHooksDir = "/usr/share/containers/oci/hooks.d" // OverrideHooksDir Directory where admin can override the default configuration OverrideHooksDir = "/etc/containers/oci/hooks.d" )
Variables ¶
This section is empty.
Functions ¶
func AddOCIHook ¶
func AddOCIHook(g *generate.Generator, hook HookParams) error
AddOCIHook generates OCI specification using the included hook
func SetupHooks ¶
func SetupHooks(hooksPath string) (map[string]HookParams, error)
SetupHooks takes a hookspath and reads all of the hooks in that directory. returning a map of the configured hooks
Types ¶
type HookParams ¶
type HookParams struct { Hook string `json:"hook"` Stage []string `json:"stage"` Cmds []string `json:"cmd"` Annotations []string `json:"annotation"` HasBindMounts bool `json:"hasbindmounts"` Arguments []string `json:"arguments"` }
HookParams is the structure returned from read the hooks configuration
Click to show internal directories.
Click to hide internal directories.