All hands-on labs

Premium Challenge labbeginnerAWS

Import an existing Amazon S3 Bucket – Challenge

Once you start using Terraform in a real environment, you will inevitably come across resources that were created manually in the AWS account and that need to be transferred over to IaC for management. Understanding how to import those resources into Terraform will save you countless hours. Practice what you've learned about the two options for importing resources with this lab environment that pre-deploys an Amazon S3 bucket.

  • No step-by-step guide
  • Terminal in the browser

Scenario

This lab is part of the Terraform on AWS course. It follows the Importing AWS resources into Terraform lesson, where you learn the two approaches for importing existing resources. Now it's time to test your new skills! If you feel you are missing context, we recommend going through that lesson first.

This is a challenge, so you start from an empty directory and write the Terraform files yourself.

For our scenario, let's say that you've just recently learned how to use Terraform in production thanks to Cybr's course. You go to your team to tell them you need to start using Terraform and IaC to manage all of your infrastructure in AWS accounts. You decide to start with one of the easiest accounts that has the fewest resources. That account has an Amazon S3 bucket that was manually created. You'd like to start by importing that resource.

How this challenge works

  • No step-by-step guide. You get the goal and the access. The path is yours to find.
  • 1 check question. Confirm you are on the right track as you go.

What you will practice

  • Find an S3 bucket that already exists in the lab account.
  • Bring the existing bucket under Terraform management without changing it.
  • Get terraform plan to report that no changes are needed.
  • Delete the imported bucket with terraform destroy.
Challenge lab

Import an existing Amazon S3 Bucket – Challenge

Included in Cybr Premium.