IP
Source Code Analysis of Kubernetes Pod IP Management
· ☕ 7 min read
1. Subnet Management by kube-controller-manager kube-controller-manager has many controllers; the one related to Pod IP is NodeIpamController. The NodeIpamController mainly manages the podcidr of nodes: when a new node joins the cluster, it allocates a subnet to that node; when a node is deleted, it reclaims the subnet. The subnets

How to Get the Real Client IP in Kubernetes
· ☕ 8 min read
Kubernetes relies on the kube-proxy component to implement Service communication and load balancing. In this process, because SNAT is used to translate the source address, a service in a Pod cannot obtain the real client IP address. This article mainly answers the question of how a workload in a Kubernetes cluster can obtain the real IP address of the client.