AWS CLI HANDS ON

AWS CLI HANDS-ON

In this article, I am going to discuss AWS CLI Hands ON. Please read our previous article where we discussed AWS CLI Setup on Linux.

AWS CLI HANDS-ON

How to create access keys click on my user and as you can see right now on the top right-hand side, I am connected using my IAM User on my account. This is something you have to do, not use your root account to create security credentials.

AWS CLI HANDS-ON Again, create Access keys. Access keys are going to be very helpful if we use the CLI. We use the command line interface if we use the SDK to implement some programming language against AWS. Going to create this Access key and they are very secret.

AWS CLI HANDS-ON

This is the only time you will see them and they can be downloaded. You cannot recover them later you can create new ones if you wanted to. I will invalidate mine after these hands-on. You can download a CSV file if you wanted to, to keep them on your computer, or show the Access key ID and the Secret access key. These are secrets and they will be worthless for you because I am going to invalidate them. Then we need to use these secret Access keys and Access key IDs. The first thing you have to do is to configure my AWS utilization. I am going to type “AWS configure”. Then I am greeted by entering my Access key ID. I can just enter this one and press Enter, and then I’m greeted by entering my Secret access key, which I will enter right here as well. The Default region name, so this is a region that is close to you, I will choose au-east-1 because I will be doing all my tutorials in au-east-1, but you will choose your own region and you can enter your own region name, the region name, by the way, you can get directly from this drop-down right here. It shows you the name of the region, as well as the region code. For me, use my eau-east-1 to press Enter. And then the Default output format, just press Enter as well.

AWS CLI HANDS-ON

So now my AWS CLI is configured. And so, we can have a look at how it works. We can do “AWS I am list-users” and press Enter, and this will list all the users in my accounts. The user I have right now is called “SANDY66”. Here is a User Id.

When he was created and when the password was last used, which is very similar to what I would get if were to go into this UI right here. The management console and the CLI do provide similar kinds of information. What happens if we remove permissions from our users? To go to admin and I am going to remove the SANDY66 user from the group admin. And so again, if go back to my user SANDY66, it does not have any permission. And I did this obviously with my root account, not the other account. My UI and obviously refresh this page, to get an error saying, “Yes, “I do not have the permissions to do this,” But let’s try to do the same thing with a CLI.

AWS CLI HANDS-ON

We get no response because it was being denied. So, the CLI permissions are obviously going to be the exact same as the permissions you get from the IAM console. You can access AWS using the management console or using the access key and secret access key that you can configure and then use in the CLI.

In the next article, I am going to discuss AWS Cloud Shell. Here, in this article, I try to explain AWS CLI Hands ON and I hope you enjoy this AWS CLI Hands ON article.

Registration Open For New Online Training

Enhance Your Professional Journey with Our Upcoming Live Session. For complete information on Registration, Course Details, Syllabus, and to get the Zoom Credentials to attend the free live Demo Sessions, please click on the below links.

Leave a Reply

Your email address will not be published. Required fields are marked *