Harsha G V
Harsha G V

Reputation: 1030

How to configure AWS tags for AWS NLB/ALB using the deployment of the ingress istio gateway?

How to configure AWS tags for AWS NLB/ALB using the deployment of the ingress istio gateway?

For e.g. when AWS NLB is created below listed default tags in aws:

kubernetes.io/service-name: istio-system/istio-ingressgateway
kubernetes.io/cluster/<kubernetes-cluster-name>: owned

Would it be possible to add user-defined tags to this NLB in AWS?

Upvotes: 2

Views: 1737

Answers (1)

Harsha G V
Harsha G V

Reputation: 1030

Found a way to add tags to NLB/ALB/ELB/ in provisioned AWS (along with security groups created for loadbalancer) for istio ingress gateway:

Using the serviceAnnotations:

service.beta.kubernetes.io/aws-load-balancer-additional-resource-tags: stringMap

e.g:

service.beta.kubernetes.io/aws-load-balancer-additional-resource-tags: "owner=gvh-ram,environment=dev,type=istio-gateway"

Started supporting this feature from below code changes to kubernetes code: https://github.com/kubernetes/cloud-provider-aws/commit/d9e60b53c67297c1667dbe0ab58a9bf65c513395

https://github.com/kubernetes/cloud-provider-aws/commit/f336a8894b2e2fcf9a7cd5176748ef4de29aed0f

For serviceAnnotations, refer: https://kubernetes-sigs.github.io/aws-load-balancer-controller/v2.1/guide/service/annotations/

For other cloud providers, refer: https://v1-18.docs.kubernetes.io/docs/concepts/cluster-administration/cloud-providers/

Upvotes: 4

Related Questions