Create a variable set in Terraform Cloud

In order for Terraform Cloud to create resources for you in AWS it needs access keys, we can provide this key using variable sets.

First step is to open settings

TerraformCloudSettings

Next we’ll click on Variable sets and create a new variable set

TerraformCloudSettings1

We’ll need to provide 3 AWS variables

  • AWS_ACCESS_KEY_ID
  • AWS_SECRET_ACCESS_KEY
  • AWS_SESSION_TOKEN

Make sure these values are environment variables & the settings box on the far right is checked, click Add variable when finished adding one variable to add the next one

TerraformCloudSettings2

Upon completion Variable sets should look like this, hit Create variable set.

TerraformCloudSettings3

Great! In the next section we’ll start working with Terraform Cloud workflows!