Kubernetes defines Service a resource type "LoadBalancer" that you can use to create a managed load balancer in SysEleven Stack for every service. To create a Kubernetes managed load balancer, use a manifest like the following:
kind: Service apiVersion: v1 metadata: name: $LOADBALANCER_NAME spec: selector: $APPLICATION_LABEL: $APPLICATION_NAME ports: - protocol: TCP port: 80 name: http - protocol: TCP port: 443 name: https type: LoadBalancer
$ kubectl get svc NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE loadbalancer LoadBalancer 10.10.10.202 220.127.116.11 80:31228/TCP,443:30279/TCP 11s
This load balancer now exposes port 80 to the outside world and maps it to port 31228 on all cluster nodes, and it exposes port 443 to the outside world and maps it to ports 30279 on all cluster nodes. This means that a loadbalancer service is also a NodePort service (i.e. a service that exposes pods on specific "NodePorts" on all nodes).