diff --git a/config.go b/config.go index 269e0cbe5..c2d987500 100644 --- a/config.go +++ b/config.go @@ -65,6 +65,6 @@ type State struct { ID string `json:"id"` // Pid is the process id for the container's main process. Pid int `json:"pid"` - // Root is the path to the container's bundle directory. - Root string `json:"root"` + // BundlePath is the path to the container's bundle directory. + BundlePath string `json:"bundlePath"` } diff --git a/runtime.md b/runtime.md index 162e73470..d3828c7d0 100644 --- a/runtime.md +++ b/runtime.md @@ -12,7 +12,7 @@ By providing a default location that container state is stored external applicat * **`version`** (string) Version of the OCI specification used when creating the container. * **`id`** (string) ID is the container's ID. * **`pid`** (int) Pid is the ID of the main process within the container. -* **`root`** (string) Root is the path to the container's bundle directory. +* **`bundlePath`** (string) BundlePath is the path to the container's bundle directory. The ID is provided in the state because hooks will be executed with the state as the payload. This allows the hook to perform clean and teardown logic after the runtime destroys its own state.