Jatin
Jatin

Reputation: 111

List all ALBs & ELBs

I am looking cmdlet to list all ALB & ELB in my account, result should only list Name, not any other parts. So example, if I can get it as below, it would be great:

ALB-11 ALB-2222 ALB111 ALB333

Upvotes: 9

Views: 10624

Answers (1)

John Rotenstein
John Rotenstein

Reputation: 269284

Use the AWS Command-Line Interface (CLI), which has a describe-load-balancers command.

For example:

aws elb describe-load-balancers --query LoadBalancerDescriptions[*].LoadBalancerName --output text

aws elbv2 describe-load-balancers --query LoadBalancers[*].LoadBalancerName --output text

Upvotes: 8

Related Questions