In this lab you will setup your brand new AWS account with an IAM User, MFA, and create an access portal. If you have not yet created an AWS account please do so before starting this lab.
This demo creates the following resources:
- An IAM Account
- MFA
- Custom access portal URL
- Access key and secret key
Before we get started I want to discuss some key terms and concepts about AWS and accounts. This is not meant to be an AWS course or AWS specific guide but I realize many who take this will be new to AWS so I want to cover it. If this information is not new to you, feel free to skip this and the suggested reading.
In AWS your account is like a container that all your resources you build such as VMs, buckets, etc, get attached to. Inside your account you can have users and roles with defined permissions, etc. All of this still lives within your account and your account will have a unique account ID that is tied to the email you used when you created it. Initially you will log into the AWS console with your root account (the account you created when you signed up) this will be your email. Root has unrestricted access to the entire AWS account and you rarely want to use this for day-to-day acitivity and creating infrastructure. This lab will walk through how to more tightely secure your root account with MFA and then create other accounts that you can use for this lab.
- Log into AWS with your root account AWS
- You can favorite it so it's easier to find later
- On the left pane you will find users and click on create user
- We're going to create a specific account for our Terraform code to use when it deploys
- We need to give this account access to perform actions in certain services like creating a VM in EC2
- Find the two built-in roles you see in the screenshot (AmazonEC2FullAccess, AmazonVPCFullAccess)
- Open the newly created iac-user account
- You can create an access key on the top right pane
- Select the other option for use case
- Give it a name to remember it by
- I recommend downloading the CSV
- Once an access key is created you can never read the secret again if you lose it
You've finished this lab and have completed the following items:
- β Created a new AWS account.
- β Logged into your AWS root account.
- β Created an AWS IAM user that will be used for Terraform.
- β Created an access key and secret key with the new user.