Skip to content

Commit

Permalink
changing permissions and python
Browse files Browse the repository at this point in the history
  • Loading branch information
matt-heery committed Mar 28, 2024
1 parent d3a7a82 commit f6d80a3
Showing 1 changed file with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,14 @@ resource "aws_s3_bucket_notification" "csv_bucket_notification" {
}


resource "aws_s3_bucket_ownership_controls" "ap_export_bucket" {
bucket = aws_s3_bucket.ap_export_bucket.id

rule {
object_ownership = "BucketOwnerPreferred"
}
}

resource "aws_s3_bucket_server_side_encryption_configuration" "ap_export_bucket" {
bucket = aws_s3_bucket.ap_export_bucket.id

Expand All @@ -97,6 +105,16 @@ data "aws_iam_policy_document" "get_json_files" {
"${aws_s3_bucket.ap_export_bucket.arn}/*",
]
}
statement {
effect = "Allow"
actions = [
"s3:PutObject",
"s3:PutObjectAcl"
]
resources = [
"arn:aws:s3:::moj-reg-dev/landing/electronic-monitoring-service/data/*"
]
}
}

resource "aws_iam_role" "em_ap_transfer_lambda" {
Expand Down

0 comments on commit f6d80a3

Please sign in to comment.