Skip to content

Commit 0442952

Browse files
add eventsub
1 parent 1290160 commit 0442952

3 files changed

Lines changed: 11 additions & 3 deletions

File tree

infrastructure/terraform/components/api/glue_crawler_event_crawler.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ resource "aws_glue_crawler" "event_crawler" {
88
s3_target {
99
path = "s3://${local.csi_global}-eventcache/"
1010
}
11+
12+
s3_target {
13+
path = "s3://${local.csi_global}-eventsubeventcache/"
14+
}
1115
recrawl_policy {
1216
recrawl_behavior = "CRAWL_EVERYTHING"
1317
}

infrastructure/terraform/components/api/iam_role_glue.tf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,8 @@ data "aws_iam_policy_document" "glue_service_policy" {
5050
"s3:DeleteObject"
5151
]
5252
resources = ["arn:aws:s3:::${local.csi}-glue-bucket/*",
53-
"arn:aws:s3:::${local.csi_global}-eventcache/*"]
53+
"arn:aws:s3:::${local.csi_global}-eventcache/*",
54+
"arn:aws:s3:::${local.csi_global}-eventsubeventcache/*"]
5455
}
5556
statement {
5657
sid = "GlueCatalogAccess"

infrastructure/terraform/components/api/s3_bucket_policy_eventcache.tf

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ data "aws_iam_policy_document" "eventcache" {
2323
]
2424

2525
resources = [
26-
"arn:aws:s3:::${local.csi_global}-eventcache"
26+
"arn:aws:s3:::${local.csi_global}-eventcache",
27+
"arn:aws:s3:::${local.csi_global}-eventsubeventcache"
28+
2729
]
2830
}
2931

@@ -45,7 +47,8 @@ data "aws_iam_policy_document" "eventcache" {
4547
]
4648

4749
resources = [
48-
"arn:aws:s3:::${local.csi_global}-eventcache/*"
50+
"arn:aws:s3:::${local.csi_global}-eventcache/*",
51+
"arn:aws:s3:::${local.csi_global}-eventsubeventcache/*"
4952
]
5053
}
5154
}

0 commit comments

Comments
 (0)