Learn the Amazon CLI simple to use

Source: Internet
Author: User
Tags aws autoscaling


List Instances of all T1.micro types
AWS EC2 describe-instances--output Table--query ' reservations[]. Instances[]. [Join (', ', tags[? key== ' Name ']. Value), Instanceid,state.name,publicdnsname] '--filters ' {"Name": "Instance-type", "Values": ["T1.micro"]} '
list the volume types for all EC2
AWS EC2 Describe-volumes--query ' volumes[*]. [Volumeid, Attachments[0]. Instanceid,volumetype] '


list Elb and the instance involved
AWS Elb Describe-load-balancers--query ' loadbalancerdescriptions[]. [Loadbalancername,instances] '
Here are some nice things:
AWS Elb Describe-load-balancers--query ' loadbalancerdescriptions[]. [Loadbalancername,join (', ', instances[]. INSTANCEID)] '

list Elb's listener
AWS Elb Describe-load-balancers--query ' loadbalancerdescriptions[]. [Loadbalancername,join (', ', instances[]. INSTANCEID), listenerdescriptions[*]] '

list CloudFront using the default SSL certificate with the custom certificate (none is using the CLOUDFRONTM default certificate)
AWS CloudFront List-distributions--query ' distributionlist.items[]. [Id,viewercertificate.iamcertificateid] '--output table
list rtmp Types
AWS CloudFront List-streaming-distributions--query ' streamingdistributionlist. Items[]. [Id,viewercertificate.iamcertificateid] '--output table
List of instance using EIP
AWS EC2 describe-addresses--output Table--filters "name=domain,values=vpc"--query "addresses[". [Instanceid,publicip] '

list autoscaling groups and the instance involved

AWS AutoScaling Describe-auto-scaling-groups--query ' autoscalinggroups[]. [Autoscalinggroupname,join (', ', Instances []. InstanceId)] '--output table

AWS AutoScaling Describe-auto-scaling-groups--query ' autoscalinggroups[]. [Autoscalinggroupname,join (', ', Instances []. InstanceId)] '--output table

This article is from the "Technical Blog" blog, please be sure to keep this source http://raytech.blog.51cto.com/7602157/1684698

Learn the Amazon CLI simple to use

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.