In this version of the API, /attach, uses hijacking to transport stdin, stdout, and stderr on the same socket.
To hint potential proxies about connection hijacking, Docker client sends connection upgrade headers similarly to websocket.
Upgrade: tcp
Connection: Upgrade
When Docker daemon detects the Upgrade header, it switches its status code from 200 OK to 101 UPGRADED and resends the same headers.