Connect to AWS

You can connect to AWS by performing the following steps:

  1. Create Environment Variables.
  2. Get AWS Caller Information.
  3. Install boto and boto3.

Prerequisites

Before you connect to AWS, you’ll need the following:

  • Active AWS account
  • Access Key
  • Secret Access Key for an existing IAM user in the AWS account

If you do not have the account and keys setup, you can do so by following the links below:

Admin Policy
The user must have the AdministratorAccess or SystemAdministrator policy assigned to it.

Create environment variables

Ansible uses AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY to authenticate to AWS.

Once you have acquired the keys, you can create the environment variable with the export command within the container.

Docker Setup
We have pre-configured the environment to save you the hassle of rebuilding and re-running your containers. All the commands will work on your local setup as well.

Run the following commands in the Ansible environment:

Get hands-on with 1200+ tech skills courses.