diff options
author | Daniel J Walsh <dwalsh@redhat.com> | 2021-04-22 15:38:36 -0400 |
---|---|---|
committer | Daniel J Walsh <dwalsh@redhat.com> | 2021-04-23 11:18:05 -0400 |
commit | 3538815c5b2b4c97304e3ea940cee414b0004d2f (patch) | |
tree | a307b133a805e47633882d2f42e65105d903b247 /libpod/container_config.go | |
parent | ba60821f0aadef99f200fa708b26fb9921ed7b70 (diff) | |
download | podman-3538815c5b2b4c97304e3ea940cee414b0004d2f.tar.gz podman-3538815c5b2b4c97304e3ea940cee414b0004d2f.tar.bz2 podman-3538815c5b2b4c97304e3ea940cee414b0004d2f.zip |
Add podman run --timeout option
This option allows users to specify the maximum amount of time to run
before conmon sends the kill signal to the container.
Fixes: https://github.com/containers/podman/issues/6412
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Diffstat (limited to 'libpod/container_config.go')
-rw-r--r-- | libpod/container_config.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libpod/container_config.go b/libpod/container_config.go index e6c3be1bd..379e17285 100644 --- a/libpod/container_config.go +++ b/libpod/container_config.go @@ -298,6 +298,8 @@ type ContainerMiscConfig struct { StopSignal uint `json:"stopSignal,omitempty"` // StopTimeout is the signal that will be used to stop the container StopTimeout uint `json:"stopTimeout,omitempty"` + // Timeout is maximimum time a container will run before getting the kill signal + Timeout uint `json:"timeout,omitempty"` // Time container was created CreatedTime time.Time `json:"createdTime"` // CgroupManager is the cgroup manager used to create this container. |