<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Ingress Archives - InfoTech Ninja</title>
	<atom:link href="https://infotechninja.com/tag/ingress/feed/" rel="self" type="application/rss+xml" />
	<link>https://infotechninja.com/tag/ingress/</link>
	<description></description>
	<lastBuildDate>Tue, 24 Mar 2026 00:00:00 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>Kubernetes Networking Explained: Pods, Services, and Ingress Controllers</title>
		<link>https://infotechninja.com/kubernetes-networking/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=kubernetes-networking</link>
		
		<dc:creator><![CDATA[Morris James]]></dc:creator>
		<pubDate>Tue, 24 Mar 2026 00:00:00 +0000</pubDate>
				<category><![CDATA[Cloud & DevOps]]></category>
		<category><![CDATA[DevOps]]></category>
		<category><![CDATA[Ingress]]></category>
		<category><![CDATA[K8s]]></category>
		<category><![CDATA[Kubernetes]]></category>
		<category><![CDATA[Networking]]></category>
		<guid isPermaLink="false">https://infotechninja.com/?p=6</guid>

					<description><![CDATA[<p>Kubernetes networking is one of the most common stumbling blocks for people transitioning from traditional VM-based infrastructure. This guide walks through every layer from pod communication to external traffic management.</p>
<p>The post <a href="https://infotechninja.com/kubernetes-networking/">Kubernetes Networking Explained: Pods, Services, and Ingress Controllers</a> appeared first on <a href="https://infotechninja.com">InfoTech Ninja</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p class="entry-lead">Kubernetes networking is one of the most common stumbling blocks for people transitioning from traditional VM-based infrastructure. The networking model is fundamentally different from what you&#8217;re used to, but once it clicks, it&#8217;s actually quite elegant. This guide walks through every layer from pod communication to external traffic management.</p>
<h2>The Flat Network Model</h2>
<p>Kubernetes enforces a fundamental networking requirement: every pod must be able to communicate directly with every other pod in the cluster, without NAT. This &#8220;flat network&#8221; model is implemented by a Container Network Interface (CNI) plugin — popular choices include Calico, Flannel, Cilium, and Weave. Each pod gets its own IP address from a cluster-wide CIDR range, and the CNI plugin is responsible for ensuring pods across different nodes can reach each other.</p>
<p>This design has important implications. Because all pods share a flat network space, network policies (covered later) are your primary isolation mechanism — without them, any pod can talk to any other pod by default. This is fine for development but should be hardened for production multi-tenant workloads. The pod IP is ephemeral: when a pod is deleted and recreated, it gets a new IP. This is why you never communicate with pods directly by IP — that&#8217;s what Services are for.</p>
<h2>Services: ClusterIP, NodePort, LoadBalancer</h2>
<p>A Service is a stable network endpoint that abstracts a set of pods. Services use label selectors to determine which pods they route traffic to — when pods are replaced (during a rolling update, for example), the Service automatically routes to the new pods without any configuration change. The kube-proxy component on each node maintains iptables or IPVS rules that implement this routing.</p>
<p>ClusterIP is the default Service type — it creates a virtual IP that&#8217;s only reachable from within the cluster. NodePort exposes the service on a static port on every node&#8217;s external IP — useful for development and simple setups, but not recommended for production. LoadBalancer provisions a cloud load balancer (an AWS ELB, GCP Load Balancer, etc.) that routes external traffic to the Service. For most production workloads, you don&#8217;t use LoadBalancer Services directly for HTTP/HTTPS — you use an Ingress controller instead.</p>
<pre><code># Service YAML — ClusterIP example for an internal API
apiVersion: v1
kind: Service
metadata:
  name: api-service
  namespace: production
spec:
  selector:
    app: api-server
    tier: backend
  ports:
    - name: http
      protocol: TCP
      port: 80
      targetPort: 8080
  type: ClusterIP
---
# LoadBalancer Service for a public-facing component
apiVersion: v1
kind: Service
metadata:
  name: frontend-lb
  namespace: production
  annotations:
    service.beta.kubernetes.io/aws-load-balancer-type: "nlb"
spec:
  selector:
    app: frontend
  ports:
    - port: 443
      targetPort: 8443
  type: LoadBalancer</code></pre>
<h2>Ingress: Your Single Entry Point</h2>
<p>An Ingress resource defines HTTP and HTTPS routing rules for external traffic entering the cluster. Instead of provisioning a separate LoadBalancer Service for every application (which creates a separate cloud load balancer and public IP for each), an Ingress controller provides a single entry point that routes traffic based on hostnames and URL paths to different backend Services. This is both more cost-effective and operationally cleaner.</p>
<p>The nginx Ingress controller is the most widely deployed, though cloud providers offer their own (AWS Load Balancer Controller, GKE Ingress). Cert-manager integrates with Ingress to automatically provision and renew TLS certificates from Let&#8217;s Encrypt, making TLS termination at the Ingress level straightforward. Combined, nginx Ingress plus cert-manager handles host-based routing and TLS for your entire cluster through a simple Ingress resource annotation.</p>
<h2>Network Policies for Pod Isolation</h2>
<p>By default, Kubernetes allows all pods to communicate with all other pods. Network Policies let you restrict this by specifying allowed ingress and egress traffic using pod selectors, namespace selectors, and IP blocks. They&#8217;re implemented by the CNI plugin (Calico and Cilium have the richest Network Policy support). A good default posture is a &#8220;deny all&#8221; baseline policy in each namespace, then explicit allow policies for required communication paths.</p>
<p>Network Policies are additive — if multiple policies apply to a pod, all of them are enforced. This makes it safe to layer policies: a namespace-wide deny-all, plus specific allows for your application tiers. Writing and testing Network Policies is notoriously tricky; tools like Cilium&#8217;s Network Policy Editor (a visual tool) combined with careful testing in a staging environment before production rollout will save you significant frustration.</p>
<pre><code># NetworkPolicy — deny all ingress to namespace, then allow specific paths
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  name: default-deny-ingress
  namespace: production
spec:
  podSelector: {}
  policyTypes:
    - Ingress
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
  name: allow-api-from-frontend
  namespace: production
spec:
  podSelector:
    matchLabels:
      app: api-server
  policyTypes:
    - Ingress
  ingress:
    - from:
        - podSelector:
            matchLabels:
              app: frontend
      ports:
        - protocol: TCP
          port: 8080</code></pre>
<p>The post <a href="https://infotechninja.com/kubernetes-networking/">Kubernetes Networking Explained: Pods, Services, and Ingress Controllers</a> appeared first on <a href="https://infotechninja.com">InfoTech Ninja</a>.</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">24</post-id>	</item>
	</channel>
</rss>
