config: Consistent Markdown/Go wording for 'hooks'
The new wording isn't particularly close to either of the old wordings, but it reads more clearly to me. I've also added our usual: (<type>, <required|optional>) to the Markdown so folks can see that this is an optional object (although see [1] for a more complete version). [1]: https://github.com/opencontainers/runtime-spec/pull/427 Subject: config: Explicitly list 'hooks' as optional Signed-off-by: W. Trevor King <wking@tremily.us>
This commit is contained in:
parent
ad81edca26
commit
9837b6b725
|
@ -251,6 +251,7 @@ _Note: For Solaris, uid and gid specify the uid and gid of the process inside th
|
|||
|
||||
## Hooks
|
||||
|
||||
**`hooks`** (object, optional) configures callbacks for container lifecycle events.
|
||||
Lifecycle hooks allow custom events for different points in a container's runtime.
|
||||
Presently there are `Prestart`, `Poststart` and `Poststop`.
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ type Spec struct {
|
|||
Hostname string `json:"hostname,omitempty"`
|
||||
// Mounts configures additional mounts (on top of Root).
|
||||
Mounts []Mount `json:"mounts,omitempty"`
|
||||
// Hooks are the commands run at various lifecycle events of the container.
|
||||
// Hooks configures callbacks for container lifecycle events.
|
||||
Hooks Hooks `json:"hooks"`
|
||||
// Annotations is an unstructured key value map that may be set by external tools to store and retrieve arbitrary metadata.
|
||||
Annotations map[string]string `json:"annotations,omitempty"`
|
||||
|
|
Loading…
Reference in New Issue