mirror of
https://github.com/containers/podman.git
synced 2026-03-13 08:01:19 +08:00
add flag "--pidfile" for podman create/run
Signed-off-by: chenkang <kongchen28@gmail.com>
This commit is contained in:
@@ -375,6 +375,9 @@ func createContainerOptions(ctx context.Context, rt *libpod.Runtime, s *specgen.
|
||||
}
|
||||
options = append(options, libpod.WithDependencyCtrs(deps))
|
||||
}
|
||||
if s.PidFile != "" {
|
||||
options = append(options, libpod.WithPidFile(s.PidFile))
|
||||
}
|
||||
return options, nil
|
||||
}
|
||||
|
||||
|
||||
@@ -171,6 +171,10 @@ type ContainerBasicConfig struct {
|
||||
// container. Dependencies can be specified by name or full/partial ID.
|
||||
// Optional.
|
||||
DependencyContainers []string `json:"dependencyContainers,omitempty"`
|
||||
// PidFile is the file that saves container process id.
|
||||
// set tags as `json:"-"` for not supported remote
|
||||
// Optional.
|
||||
PidFile string `json:"-"`
|
||||
}
|
||||
|
||||
// ContainerStorageConfig contains information on the storage configuration of a
|
||||
|
||||
Reference in New Issue
Block a user