Skip to content

Commit

Permalink
Merge branch 'inline-tmp-bucket-policy'
Browse files Browse the repository at this point in the history
  • Loading branch information
tsibley committed Feb 16, 2024
2 parents d579ab5 + 9e2b171 commit 6fd2f21
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 45 deletions.
37 changes: 0 additions & 37 deletions env/production/aws-iam-policy-AllowEditingOfNextstrainTmpBucket.tf

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,36 @@ resource "aws_iam_role" "GitHubActionsRoleNextstrainTmpBucket" {
]
})

/* XXX TODO: Inline this instead to avoid clutter if the policy isn't going
* to get used elsewhere?
* -trs, 5 Feb 2024 (originally 12 June 2023¹)
*
* ¹ <https://github.com/nextstrain/private/issues/22#issuecomment-1588211457>
*/
managed_policy_arns = [aws_iam_policy.AllowEditingOfNextstrainTmpBucket.arn]
inline_policy {}
inline_policy {
name = "nextstrain-tmp"
policy = jsonencode({
"Version": "2012-10-17",
"Statement": [
{
"Sid": "BucketActions",
"Effect": "Allow",
"Action": [
"s3:ListBucket"
],
"Resource": [
"arn:aws:s3:::nextstrain-tmp"
]
},
{
"Sid": "ObjectActions",
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:GetObjectVersion",
"s3:PutObject",
"s3:DeleteObject"
],
"Resource": [
"arn:aws:s3:::nextstrain-tmp/*"
]
}
]
})
}
managed_policy_arns = []
}

0 comments on commit 6fd2f21

Please sign in to comment.