ANS-C01 Question 94
Select 3You are managing a Kubernetes cluster running on Amazon EKS and need to expose an application externally using an Elastic Load Balancer (ELB). You have already deployed the AWS Load Balancer Controller in your cluster. What steps must you take to ensure the application is exposed via an Application Load Balancer (ALB)?
- A
Annotate the Kubernetes service with
service.beta.kubernetes.io/aws-load-balancer-type: alb. - B
Create an Ingress resource with the appropriate rules and annotations for the AWS Load Balancer Controller.
- C
Ensure the IAM role associated with the AWS Load Balancer Controller has the required permissions for ALB provisioning.
- D
Configure the target type for the ALB as
Instanceinstead ofIPin the Kubernetes manifest. - E
Manually create an ALB in the AWS Management Console and associate it with the Kubernetes service.
Show answer and explanation
Correct answers: A, B, C
Explanation
To expose an application externally via an Application Load Balancer (ALB) using the AWS Load Balancer Controller, you must annotate the service, create an Ingress resource with routing rules, and ensure the controller has the required IAM permissions. These steps enable the controller to automatically provision and manage the ALB. Manually creating the ALB or configuring its target type is not required, as these tasks are handled by the AWS Load Balancer Controller.
- A. Correct.
Correct. The annotation
service.beta.kubernetes.io/aws-load-balancer-type: albspecifies that the service should use an Application Load Balancer (ALB). Without this annotation, the controller will not provision an ALB. - B. Correct.
Correct. The AWS Load Balancer Controller uses Kubernetes Ingress resources to define routing rules for the ALB. You must create an Ingress resource with appropriate annotations and rules.
- C. Correct.
Correct. The AWS Load Balancer Controller requires IAM permissions to manage and provision ALBs. The associated IAM role must have the necessary permissions, such as
elasticloadbalancing:*for ALB operations. - D. Incorrect.
Incorrect. The target type for ALBs is automatically determined by the controller, depending on the configuration of the Kubernetes cluster. You do not need to manually configure it in the manifest.
- E. Incorrect.
Incorrect. The AWS Load Balancer Controller automates the provisioning and management of ALBs. Manually creating an ALB in the AWS Management Console is unnecessary and not aligned with the Kubernetes-native approach.