Rancher Hosts and Squid

We have a environment where all traffic going out through squid. I am unable to add rancher hosts behind the squid where rancher server can only accessible through squid. Rancher server is also sitting behind the squid. I use http_proxy,https_proxy parameters to launch the agent… it successfully launches the first and subsequent rancher_agent container, but it going into some error while executing a script named pyagent.

Following is the error from rancher_agent container logs and its stuck there and not able to launch any more infrastructure service containers. Any help?

[apply.sh:82] exec /var/lib/cattle/pyagent/agent
time=“2017-05-11T15:04:02Z” level=info msg="Launching agent"
time=“2017-05-11T15:04:02Z” level=info msg="https://rancher.domain.com/v1E00DF2F6ED7D6A9915D6zwUV1fFTYM89scSgsL5iNrY4kf4Lbb9FX4mdmwq4"
time=“2017-05-11T15:04:02Z” level=info msg="Listening for events on https://rancher.domain.com/v1"
time=“2017-05-11T15:04:02Z” level=info msg="launching hostapi"
time=“2017-05-11T15:04:03Z” level=info msg=“Initializing event router” workerCount=250
time=“2017-05-11T15:04:03Z” level=info msg="Starting event router."
time=“2017-05-11T15:04:03Z” level=debug msg="Processing event: &events.Message{Status:“start”, ID:

“f11c713f2fe6311369aadd41824a3028738ecc0d03f4856e17cfed19ee863352”, From:"-simulated-", Type:"", Action:"", Actor:events.Actor{ID:"", Attributes:map[string]

string(nil)}, Time:0, TimeNano:0}"
time=“2017-05-11T15:04:03Z” level=error msg="invalid character ‘b’ looking for beginning of value"
time=“2017-05-11T15:04:09Z” level=error msg="invalid character ‘c’ looking for beginning of value"
time=“2017-05-11T15:04:15Z” level=error msg="invalid character ‘c’ looking for beginning of value"
time=“2017-05-11T15:04:20Z” level=error msg="invalid character ‘c’ looking for beginning of value

Rancher relies on communication over websockets between the hosts and the server. Unfortunately, Squid doesn’t properly support websockets.

Thank you for your reply @cjellick. I was trying to find a solution for it for a few months. I made a typo in the previous post… Rancher server is behind haproxy, not squid.
But rancher hosts are are supposed to communicate to rancher server using squid itself. Will that configuration also fail? Rancher documentation describes about how can we configure http_proxy for rancher hosts, does that mean its supported by some other proxies?

Could you please confirm cjellick? Cause its very important for our setup. Guess , in almost all production environments, people are going to use proxies for outgoing traffic. Would we be able to add hosts if its behind a proxy?

Even with HAProxy between, Squid needs to support the websocket connection(s) that are established. From what I could find, it doesn’t support it.