From 62b0a853e4851b843ad076035c48f2f8be81375c Mon Sep 17 00:00:00 2001 From: Adrian Stobbe Date: Tue, 11 Jul 2023 18:14:13 +0200 Subject: [PATCH] doc AWS internet LB + add to LB test --- .github/actions/e2e_lb/lb.yml | 2 ++ docs/docs/workflows/lb.md | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/.github/actions/e2e_lb/lb.yml b/.github/actions/e2e_lb/lb.yml index a5a48fab1..7d0924d26 100644 --- a/.github/actions/e2e_lb/lb.yml +++ b/.github/actions/e2e_lb/lb.yml @@ -3,6 +3,8 @@ kind: Service metadata: name: whoami namespace: lb-test + annotations: + service.beta.kubernetes.io/aws-load-balancer-scheme: internet-facing spec: selector: app: whoami diff --git a/docs/docs/workflows/lb.md b/docs/docs/workflows/lb.md index b39941b6c..c86866fd7 100644 --- a/docs/docs/workflows/lb.md +++ b/docs/docs/workflows/lb.md @@ -1 +1,11 @@ # Expose services + +## Internet-facing LB service on AWS + +To expose your application service externally you might want to use a Kubernetes Service of type `LoadBalancer`. On AWS, load-balancing is achieved through the [AWS Load Balancing Controller](https://kubernetes-sigs.github.io/aws-load-balancer-controller) as in the managed EKS. + +Since recent versions, the controller deploy an internal LB by default requiring to set an annotation `service.beta.kubernetes.io/aws-load-balancer-scheme: internet-facing` in order to have an internet-facing LB. For more details, see the [official docs](https://kubernetes-sigs.github.io/aws-load-balancer-controller/v2.2/guide/service/nlb/). + +:::caution +Before terminating the cluster, all LB backed services should be deleted, so that the controller can cleanup the related resources. +:::