Interview Prep/Networking/Kubernetes & Service Networking in Production

How do you expose non-HTTP services (TCP, UDP) from Kubernetes?

IntermediateProductionKubernetes & Service Networking in Production
Answer

A Service of type LoadBalancer using an NLB (annotation service.beta.kubernetes.io/aws-load-balancer-type: external with the AWS Load Balancer Controller), or TCPRoute/UDPRoute in the Gateway API, or ingress-nginx TCP services ConfigMap.

Mind security groups on nodes and pods, health check settings and source IP preservation. For UDP also consider conntrack and idle timeouts (NLB UDP idle timeout is 120 seconds).

All Networking questions Roadmap: Networking for DevOps

More on Kubernetes & Service Networking in Production