How to setup Kubernetes clustors in HTTP Proxy corporate environment

HTTP Proxy corporate environment for kubernetes can be fixed by including all my cluster node IPs in NO_PROXY and using the same NO_PROXY on all the minions when joining the cluster. In short…

kubeadm gets and checks environment from your currently running session. You can see what do you have if you execute $ env | grep -i _proxy= | sort. E.g. inside our company firewall I have something like this:

In order to setup Kubernetes clustors in HTTP Proxy corporate environment, we need to have http_proxy and https_proxy (lower and uppercase environment variables) pointing to the proxy server, and no_proxy set to IPs that should not go through the proxy server.

For this system, no_proxy had the host IP,, and then the IPs for the IPv4 pool and IPs for the service IPs. The defaults use large subnets, so Ankur reduced these to help make the no-proxy setting more manageable.

For the IPv4 pool, if using (reduced size from default), and for the kubernetes service IP subnet, if using these lines in .bashrc to create the no_proxy setting (gedit .bashrc):

Rajesh Kumar
Total Page Visits: 68 - Today Page Visits: 2