<p>We are using GKE in kubernatees, and we are using <strong>10.0.0.0/8</strong> cidr range for all our private ips which is shared with our on-prem and AWS network as well.</p>
<p>out pods and service ip from K8 cluster is from non rfs <strong>240.0.120.0/24</strong> cidr range.  Now this is the issue, when we try to connect any GCP or AWS resource it's not able to connect and needs masquerading.</p>
<p>However, masquerading document says it's wont' masquerade if destination IP is from cidr <strong>10.0.0.0/8</strong></p>
<p>**links I am referring too **</p>
<ul>
<li><a href="https://github.com/kubernetes-sigs/ip-masq-agent#agent-flags" rel="nofollow noreferrer">https://github.com/kubernetes-sigs/ip-masq-agent#agent-flags</a></li>
<li><a href="https://cloud.google.com/kubernetes-engine/docs/concepts/ip-masquerade-agent" rel="nofollow noreferrer">https://cloud.google.com/kubernetes-engine/docs/concepts/ip-masquerade-agent</a></li>
<li><a href="https://cloud.google.com/kubernetes-engine/docs/concepts/ip-masquerade-agent#default-non-masq-dests" rel="nofollow noreferrer">https://cloud.google.com/kubernetes-engine/docs/concepts/ip-masquerade-agent#default-non-masq-dests</a></li>
</ul>
<p>I am confuse what to do, there is not section in ConfigMap to add <strong>masqueradeCIDRs</strong>, it only has a section to add <strong>nonMasqueradeCIDRs</strong></p>

Gaurang Shah
<p>The ConfigMao for ip-masq lists the CIDRs for which you do not want to masquerade.  If you don't specify a ConfigMap, then the default includes <code>10.0.0.0/8</code> in the non-masquerade list.</p>
<p>You'll need to follow the docs on <a href="https://cloud.google.com/kubernetes-engine/docs/how-to/ip-masquerade-agent#creating_the_ip-masq-agent_configmap" rel="nofollow noreferrer">creating the ConfigMap</a> and you'll need to minimally add the ranges you use for your pods/services (the 240.) to the non-masquerade list.  You want to make sure the <code>10.0.0.0/8</code> is NOT in the ConfigMap.</p>
