module "aws-glue-scripts-023180329437-eu-central-1" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "aws-glue-scripts-023180329437-eu-central-1"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.aws-glue-scripts-023180329437-eu-central-1.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "aws-glue-scripts-023180329437-eu-central-1",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "del-p2-vpc-flow-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "del-p2-vpc-flow-logs"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.del-p2-vpc-flow-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags                                  = merge(var.tags, { Name = "del-p2-vpc-flow-logs" }, { Purpose = "CLOUDOPS" })
}

module "delivery-s3-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delivery-s3-logs"
  versioning = {
    enabled = true
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "sme-aoma-delivery-prod-eu-central-1-logs"
    target_prefix = "delivery-s3-logs/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delivery-s3-logs.json
  attach_deny_insecure_transport_policy = false
  attach_require_latest_tls_policy      = false
  tags = merge(var.tags,
    {
      Name           = "delivery-s3-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "LOGGING"
  })
}


module "delp-mrap-us" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-mrap-us"
  versioning = {
    enabled = false
  }
  server_side_encryption_configuration  = var.server_side_encryption_configuration
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-mrap-us.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "delp-mrap-us",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "delp-mrap-eu" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-mrap-eu"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-mrap-eu.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "delp-mrap-eu",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}
module "delp-ansible" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-ansible"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-ansible.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "delp-ansible",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"

    }

  )
}

module "delp-aws-waf-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-aws-waf-logs"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-aws-waf-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "delp-aws-waf-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "delp-frankfurt-elb-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-frankfurt-elb-logs"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-frankfurt-elb-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "delp-frankfurt-elb-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "dspc-ansible" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "dspc-ansible"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.dspc-ansible.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "dspc-ansible",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-amazon-lfv-dropoff" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-amazon-lfv-dropoff"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-amazon-lfv-dropoff.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-amazon-lfv-dropoff",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-aoma-delivery-prod-athena-out" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-athena-out"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-athena-out.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-athena-out",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-aoma-delivery-prod-awsconfig-prod" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-awsconfig-prod"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-awsconfig-prod.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-awsconfig-prod",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-aoma-delivery-prod-db-team" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-db-team"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-db-team.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-db-team",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-aoma-delivery-prod-eu-central-1-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-eu-central-1-logs"
  versioning = {
    enabled = true
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-eu-central-1-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags                                  = merge(var.tags, { Name = "sme-aoma-delivery-prod-eu-central-1-logs" })
}

module "sme-aoma-delivery-prod-us-east-1-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-us-east-1-logs"
  versioning = {
    enabled = true
  }

  server_side_encryption_configuration  = var.server_side_encryption_configuration
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-us-east-1-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags                                  = merge(var.tags, { Name = "sme-aoma-delivery-prod-us-east-1-logs" })
}

module "sme-aoma-delivery-prod-eu-west-2-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-eu-west-2-logs"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-west-2
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration

  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-eu-west-2-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags                                  = merge(var.tags, { Name = "sme-aoma-delivery-prod-eu-west-2-logs" }, { Purpose = "LOGGING" })
}

module "sme-aoma-delivery-prod-euc1-s3-inventory" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-euc1-s3-inventory"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-euc1-s3-inventory.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-euc1-s3-inventory",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"

  })
}

module "sme-aoma-delivery-prod-euw2-s3-inventory" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-euw2-s3-inventory"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-west-2
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "sme-aoma-delivery-prod-eu-west-2-logs"
    target_prefix = "sme-aoma-delivery-prod-euw2-s3-inventory/"
  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-euw2-s3-inventory.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-euw2-s3-inventory",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-aoma-delivery-prod-rds-backups" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-rds-backups"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-rds-backups.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-eu-central-1-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-aoma-delivery-prod-ssm-out" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-ssm-out"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-ssm-out.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {

      Name           = "sme-aoma-delivery-prod-ssm-out",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"

  })
}

module "sme-aoma-delivery-prod-us-west-2-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-us-west-2-logs"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.us-west-2
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration

  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-us-west-2-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-us-west-2-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "LOGGING"

  })
}

module "sme-conversion-shelf" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-conversion-shelf"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-conversion-shelf.json
  attach_deny_insecure_transport_policy = false
  attach_require_latest_tls_policy      = false
  tags = merge(var.tags,
    {

      Name           = "sme-conversion-shelf",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT",
      s3-bucket-name = "sme-conversion-shelf"
  })
}

module "sme-delivery-cf-logs" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delivery-cf-logs"
  versioning = {
    enabled = false
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration

  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-delivery-cf-logs.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,

    {

      Name           = "sme-delivery-cf-logs",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"

  })
}

module "sme-delivery-messages-prod" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delivery-messages-prod"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-delivery-messages-prod.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-delivery-messages-prod",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-delivery-target" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delivery-target"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-delivery-target.json
  attach_deny_insecure_transport_policy = false
  attach_require_latest_tls_policy      = false
  tags = merge(var.tags,
    {

      Name           = "sme-delivery-target",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"

  })
}

module "sme-dfclight" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-dfclight"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-dfclight.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-dfclight",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-media-production" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-media-production"
  versioning = {
    enabled = false
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "sme-aoma-delivery-prod-us-east-1-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-media-production.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {

      Name           = "sme-media-production",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-netezza-delivery-01" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-netezza-delivery-01"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-netezza-delivery-01.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,

    {
      Name           = "sme-netezza-delivery-01",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-netezza-delivery-02" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-netezza-delivery-02"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-netezza-delivery-02.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-netezza-delivery-02",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-pitch-content-dropoff" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-pitch-content-dropoff"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration

  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-pitch-content-dropoff.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-pitch-content-dropoff",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-s3-inventory" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-s3-inventory"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-s3-inventory.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-s3-inventory",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "target-bucket-athena-query-result" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "target-bucket-athena-query-result"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.target-bucket-athena-query-result.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "target-bucket-athena-query-result",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}


module "delp-lambdas-state" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "delp-lambdas-state"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.delp-lambdas-state.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {

      Name           = "delp-lambdas-state",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}


module "sme-delivery-user-upload" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delivery-user-upload"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership        = "BucketOwnerEnforced"
  block_public_acls       = var.block_public_acls
  ignore_public_acls      = var.ignore_public_acls
  restrict_public_buckets = var.restrict_public_buckets
  block_public_policy     = var.block_public_policy
  force_destroy           = var.force_destroy
  attach_policy           = var.attach_policy
  #policy                                = data.aws_iam_policy_document.sme-delivery-user-upload.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {

      Name           = "sme-delivery-user-upload",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}


module "sme-delivery-aoma-upload" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delivery-aoma-upload"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-delivery-aoma-upload.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {

      Name           = "sme-delivery-aoma-upload",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}

module "sme-aoma-delivery-prod-dw" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-aoma-delivery-prod-dw"
  versioning = {
    enabled = false
  }
  providers = {
    aws = aws.eu-central-1
  }
  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "delivery-s3-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }
  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-aoma-delivery-prod-dw.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy
  tags = merge(var.tags,
    {
      Name           = "sme-aoma-delivery-prod-dw",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "CLOUDOPS"
  })
}

module "sme-delp-watermarking" {
  #checkov:skip=CKV_AWS_19: Ensure all data stored in the S3 bucket is securely encrypted at rest
  #checkov:skip=CKV_AWS_145: Ensure that S3 buckets are encrypted with KMS by default
  #checkov:skip=CKV_AWS_21: Ensure all data stored in the S3 bucket have versioning enabled
  #checkov:skip=CKV_AWS_300: Ensure S3 lifecycle configuration sets period for aborting failed uploads
  source  = "terraform-aws-modules/s3-bucket/aws"
  version = "~> 3.11.0"
  bucket  = "sme-delp-watermarking"
  versioning = {
    enabled = false
  }

  server_side_encryption_configuration = var.server_side_encryption_configuration
  logging = {
    target_bucket = "sme-aoma-delivery-prod-us-east-1-logs"
    target_prefix = "sme-aoma-delivery-prod/"

  }

  object_ownership                      = "BucketOwnerEnforced"
  block_public_acls                     = var.block_public_acls
  ignore_public_acls                    = var.ignore_public_acls
  restrict_public_buckets               = var.restrict_public_buckets
  block_public_policy                   = var.block_public_policy
  force_destroy                         = var.force_destroy
  attach_policy                         = var.attach_policy
  policy                                = data.aws_iam_policy_document.sme-delp-watermarking.json
  attach_deny_insecure_transport_policy = var.attach_deny_insecure_transport_policy
  attach_require_latest_tls_policy      = var.attach_require_latest_tls_policy

  tags = merge(var.tags,
    {
      Name           = "sme-delp-watermarking",
      Environment    = "Prod",
      Terraform      = "True",
      Business-Unit  = "Delivery-Services",
      Classification = "internal-use-only",
      Project-Name   = "Delivery",
      Project-Code   = "SME-2000-0306B",
      Owner          = "Vijay Subramaniam",
      map-migrated   = "migKNBMDMW06I",
      Purpose        = "APP-SUPPORT"
  })
}
