diff --git a/README.md b/README.md index 1b2daef..cbb8ffd 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ This month we're going to explore the world of chaos engineering, using Amazon's 1. If you're following along in your own time, you'll need: * An AWS account * Terraform installed - +1. The AWS account must contain an S3 bucket that will be used to store asset files. ## Live workshop environments diff --git a/images/apache_splash.png b/images/apache_splash.png new file mode 100644 index 0000000..1ed604b Binary files /dev/null and b/images/apache_splash.png differ diff --git a/images/halloween_panda.png b/images/halloween_panda.png new file mode 100644 index 0000000..14103c2 Binary files /dev/null and b/images/halloween_panda.png differ diff --git a/steps/init/data.tf b/steps/init/data.tf index deb39a4..fe97a60 100644 --- a/steps/init/data.tf +++ b/steps/init/data.tf @@ -5,4 +5,8 @@ data "aws_availability_zones" "available_azs" { data "aws_caller_identity" "current" { +} + +data "aws_s3_bucket" "playground_assets" { + bucket = "${local.account_id}-${var.region}-oct-assets" } \ No newline at end of file diff --git a/steps/init/outputs.tf b/steps/init/outputs.tf index a5fe1a4..3c31aba 100644 --- a/steps/init/outputs.tf +++ b/steps/init/outputs.tf @@ -1,11 +1,11 @@ output "asset_bucket_arn" { description = "ARN of the asset bucket." - value = aws_s3_bucket.playground_assets.arn + value = data.aws_s3_bucket.playground_assets.arn } output "asset_bucket_name" { description = "name of the asset bucket." - value = aws_s3_bucket.playground_assets.id + value = data.aws_s3_bucket.playground_assets.id } output "public_subnet_details" { diff --git a/steps/init/s3.tf b/steps/init/s3.tf deleted file mode 100644 index 382e2f4..0000000 --- a/steps/init/s3.tf +++ /dev/null @@ -1,10 +0,0 @@ -resource "aws_s3_bucket" "playground_assets" { - bucket = "${local.account_id}-${var.region}-oct-assets" - - force_destroy = true # Destroy all objects in the bucket before destroying the bucket -} - -import { - to = aws_s3_bucket.playground_assets - id = var.asset_bucket -} \ No newline at end of file