# This defines the EMR Setup for data processing # It setups all Buckets, Account B Roles and Bucket Policies needed. # THIS CODE IS NOT FOR PRODUCTIVE USE. TEST/TRANING CODE ONLY # (c) by David Surey - Amazon Web Services EMEA SARL # 10/2019 - suredavi@amazon.de # Create the Source files bucket resource "aws_s3_bucket" "sourcebucket" { provider = aws.storage bucket = "${var.sourcebucket}" } # Create the Destination files bucket resource "aws_s3_bucket" "destinationbucket" { provider = aws.storage bucket = "${var.destinationbucket}" } # Create the role to be assumed by the jupyter notebooks resource "aws_iam_role" "storage_emr_notebook_role" { name = "storage_emr_notebook_role" provider = aws.storage assume_role_policy = <