Complete the code to import an existing AWS S3 bucket into Terraform state.
terraform import aws_s3_bucket.my_bucket [1]
You need to specify the actual name of the existing bucket to import it into Terraform state.
Complete the Terraform resource block to define an imported AWS EC2 instance.
resource "aws_instance" "[1]" { # Configuration will be managed after import }
The resource name should reflect the imported resource, such as 'existing_instance' for clarity.
Fix the error in the import command to correctly import an existing AWS VPC with ID 'vpc-123abc'.
terraform import [1] vpc-123abc
The import command requires the Terraform resource address, which includes the resource type and resource name defined in the configuration, such as 'aws_vpc.my_vpc'.
Fill both blanks to complete the Terraform import command for an existing AWS IAM role named 'admin-role'.
terraform import [1] [2]
The import command needs the full resource address and the actual resource ID. Here, 'aws_iam_role.admin' is the resource address and 'admin-role' is the IAM role name in AWS.
Fill all three blanks to define a Terraform resource block for an imported AWS RDS instance named 'db-instance' with identifier 'prod-db'.
resource "[1]" "[2]" { identifier = "[3]" # Additional configuration after import }
The resource type is 'aws_db_instance', the resource name can be 'imported_db' to indicate it is imported, and the identifier is the actual RDS instance ID 'prod-db'.