summaryrefslogtreecommitdiff
path: root/cmd/podman/common
diff options
context:
space:
mode:
authorQi Wang <qiwan@redhat.com>2020-06-16 14:22:05 -0400
committerQi Wang <qiwan@redhat.com>2020-06-19 09:40:13 -0400
commitf61a7f25a8a6ec27fec069989f4b19b2ea19fc75 (patch)
tree6e6065b6a5456c66116ebc5c4bec7395df4bac5c /cmd/podman/common
parent5ec29f8d4e79500915ec79824d9eb21630205f3f (diff)
downloadpodman-f61a7f25a8a6ec27fec069989f4b19b2ea19fc75.tar.gz
podman-f61a7f25a8a6ec27fec069989f4b19b2ea19fc75.tar.bz2
podman-f61a7f25a8a6ec27fec069989f4b19b2ea19fc75.zip
Add --preservefds to podman run
Add --preservefds to podman run. close https://github.com/containers/libpod/issues/6458 Signed-off-by: Qi Wang <qiwan@redhat.com>
Diffstat (limited to 'cmd/podman/common')
-rw-r--r--cmd/podman/common/create_opts.go1
-rw-r--r--cmd/podman/common/specgen.go1
2 files changed, 2 insertions, 0 deletions
diff --git a/cmd/podman/common/create_opts.go b/cmd/podman/common/create_opts.go
index 49052704e..4f3b8b322 100644
--- a/cmd/podman/common/create_opts.go
+++ b/cmd/podman/common/create_opts.go
@@ -69,6 +69,7 @@ type ContainerCLIOpts struct {
PIDsLimit int64
Pod string
PodIDFile string
+ PreserveFDs uint
Privileged bool
PublishAll bool
Pull string
diff --git a/cmd/podman/common/specgen.go b/cmd/podman/common/specgen.go
index e6a524358..599e003e8 100644
--- a/cmd/podman/common/specgen.go
+++ b/cmd/podman/common/specgen.go
@@ -609,6 +609,7 @@ func FillOutSpecGen(s *specgen.SpecGenerator, c *ContainerCLIOpts, args []string
}
s.LogConfiguration.Options = logOpts
s.Name = c.Name
+ s.PreserveFDs = c.PreserveFDs
s.OOMScoreAdj = &c.OOMScoreAdj
if c.Restart != "" {