diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2019-05-01 14:51:55 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-01 14:51:55 +0200 |
commit | eea77b5ae3e7fb8a60d438a79d3a4b30d35bb67c (patch) | |
tree | 37f8f7740e9e615a561422410ff91a0ce13bead0 /cmd | |
parent | 39c937ee450a4de7ab97c013d65157a3b39718b1 (diff) | |
parent | 354d80626ac4790f261a29a6d53d6cd3fa837bb9 (diff) | |
download | podman-eea77b5ae3e7fb8a60d438a79d3a4b30d35bb67c.tar.gz podman-eea77b5ae3e7fb8a60d438a79d3a4b30d35bb67c.tar.bz2 podman-eea77b5ae3e7fb8a60d438a79d3a4b30d35bb67c.zip |
Merge pull request #3018 from jamescassell/auto-http-proxy
Auto http proxy
Diffstat (limited to 'cmd')
-rw-r--r-- | cmd/podman/common.go | 4 | ||||
-rw-r--r-- | cmd/podman/shared/create.go | 1 | ||||
-rw-r--r-- | cmd/podman/shared/intermediate.go | 1 |
3 files changed, 6 insertions, 0 deletions
diff --git a/cmd/podman/common.go b/cmd/podman/common.go index eac96d3ba..b02aa5990 100644 --- a/cmd/podman/common.go +++ b/cmd/podman/common.go @@ -313,6 +313,10 @@ func getCreateFlags(c *cliconfig.PodmanCommand) { "hostname", "h", "", "Set container hostname", ) + createFlags.Bool( + "http-proxy", true, + "Set proxy environment variables in container based on the host proxy vars", + ) createFlags.String( "image-volume", cliconfig.DefaultImageVolume, "Tells podman how to handle the builtin image volumes. The options are: 'bind', 'tmpfs', or 'ignore'", diff --git a/cmd/podman/shared/create.go b/cmd/podman/shared/create.go index c521f9cb6..48476e177 100644 --- a/cmd/podman/shared/create.go +++ b/cmd/podman/shared/create.go @@ -624,6 +624,7 @@ func ParseCreateOpts(ctx context.Context, c *GenericCLIResults, runtime *libpod. GroupAdd: c.StringSlice("group-add"), Hostname: c.String("hostname"), HostAdd: c.StringSlice("add-host"), + HTTPProxy: c.Bool("http-proxy"), NoHosts: c.Bool("no-hosts"), IDMappings: idmappings, Image: imageName, diff --git a/cmd/podman/shared/intermediate.go b/cmd/podman/shared/intermediate.go index 9c494dec5..a38e4d47a 100644 --- a/cmd/podman/shared/intermediate.go +++ b/cmd/podman/shared/intermediate.go @@ -404,6 +404,7 @@ func NewIntermediateLayer(c *cliconfig.PodmanCommand, remote bool) GenericCLIRes m["healthcheck-start-period"] = newCRString(c, "healthcheck-start-period") m["healthcheck-timeout"] = newCRString(c, "healthcheck-timeout") m["hostname"] = newCRString(c, "hostname") + m["http-proxy"] = newCRBool(c, "http-proxy") m["image-volume"] = newCRString(c, "image-volume") m["init"] = newCRBool(c, "init") m["init-path"] = newCRString(c, "init-path") |