Skip to content

Commit ef89891

Browse files
committed
Merge pull request moby#22888 from ibuildthecloud/host-compat
Remove DOCKER_HTTP_HOST_COMPAT env var
2 parents 11ddfa4 + 989f6f8 commit ef89891

2 files changed

Lines changed: 6 additions & 22 deletions

File tree

cmd/dockerd/daemon_unix.go

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -114,14 +114,12 @@ func notifyShutdown(err error) {
114114
}
115115

116116
func wrapListeners(proto string, ls []net.Listener) []net.Listener {
117-
if os.Getenv("DOCKER_HTTP_HOST_COMPAT") != "" {
118-
switch proto {
119-
case "unix":
120-
ls[0] = &hack.MalformedHostHeaderOverride{ls[0]}
121-
case "fd":
122-
for i := range ls {
123-
ls[i] = &hack.MalformedHostHeaderOverride{ls[i]}
124-
}
117+
switch proto {
118+
case "unix":
119+
ls[0] = &hack.MalformedHostHeaderOverride{ls[0]}
120+
case "fd":
121+
for i := range ls {
122+
ls[i] = &hack.MalformedHostHeaderOverride{ls[i]}
125123
}
126124
}
127125
return ls

docs/reference/commandline/dockerd.md

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -850,20 +850,6 @@ set like this:
850850
export DOCKER_TMPDIR=/mnt/disk2/tmp
851851
/usr/local/bin/dockerd -D -g /var/lib/docker -H unix:// > /var/lib/docker-machine/docker.log 2>&1
852852
853-
Docker clients <= 1.9.2 used an invalid Host header when making request to the
854-
daemon. Docker 1.12 is built using golang 1.6 which is now checking the validity
855-
of the Host header and as such clients <= 1.9.2 can't talk anymore to the daemon.
856-
Docker supports overcoming this issue via a Docker daemon
857-
environment variable. In case you are seeing this error when contacting the
858-
daemon:
859-
860-
Error response from daemon: 400 Bad Request: malformed Host header
861-
862-
The `DOCKER_HTTP_HOST_COMPAT` can be set like this:
863-
864-
DOCKER_HTTP_HOST_COMPAT=1 /usr/local/bin/dockerd ...
865-
866-
867853
## Default cgroup parent
868854
869855
The `--cgroup-parent` option allows you to set the default cgroup parent

0 commit comments

Comments
 (0)