How to use AWS cli

how to use aws cli
how to use cli in ubuntu

What is AWSCLI?

How to use AWS cli 1

how to use cli in ubuntu

AWS Command Line Interface

It is an Open-Source tool which enables us to interact with AWS services using Command-Line. It allows us to perform functionality through commands that are equivalent to the Browser-AWS GUI management console.

How to install awscli in Linux (ubuntu)?

apt install awscli

How to configure the AWS CLI ?

aws configure
AWS Secret Access Key [None]: wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
Default region name [None]: us-west-2
Default output format [None]: json

Multiple profiles can be added to the awscli

Now we need to check if we have configured the credentials perfectly or not

aws ec2 describe-regions --output table

List the aws configured file and secure keys

ls ~/.aws

aws ec2 describe-instances --profile user2

export AWS_PROFILE=user2

The following example shows how you would configure environment variables for the default user from earlier in this guide.

Linux, macOS, or Unix

$ export AWS_DEFAULT_REGION=us-west-2

How to reconfigure the AWS CLI

aws configure --profile profilename

aws ec2 describe-instances --output table --region us-east-1

aws ec2 describe-instances --output table --region us-west-1


I love helping beautiful people like you. I love hanging out with my dogs.

You may also like...

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.