File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed
Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -13,4 +13,7 @@ module "mesh" {
1313 handshake_schedule = " rate(24 hours)"
1414
1515 account_id = local. immunisation_account_id
16+ # TODO these need enviroment specific names to avoid conflicts
17+ mesh_bucket_name = " local-immunisation-mesh"
18+ mesh_logs_bucket_name = " local-immunisation-mesh-s3logs"
1619}
Original file line number Diff line number Diff line change 88 mesh_processor_lambda_dir = abspath (" ${ path . root } /../mesh_processor" )
99 mesh_processor_lambda_files = fileset (local. mesh_processor_lambda_dir , " **" )
1010 mesh_processor_lambda_dir_sha = sha1 (join (" " , [for f in local . mesh_processor_lambda_files : filesha1 (" ${ local . mesh_processor_lambda_dir } /${ f } " )]))
11+ mesh_s3_bucket_name = local. is_mesh_enabled ? module. mesh [0 ]. mesh_bucket_name : null
12+ mesh_s3_logs_bucket_name = local. is_mesh_enabled ? module. mesh [0 ]. mesh_logs_bucket_name : null
1113}
1214
1315resource "aws_ecr_repository" "mesh_file_converter_lambda_repository" {
@@ -140,6 +142,9 @@ resource "aws_iam_policy" "mesh_processor_lambda_exec_policy" {
140142 " s3:DeleteObject"
141143 ]
142144 Resource = [
145+ " arn:aws:s3:::${ local . mesh_s3_bucket_name } " ,
146+ " arn:aws:s3:::${ local . mesh_s3_bucket_name } /*" ,
147+ " arn:aws:s3:::${ local . mesh_s3_logs_bucket_name } /*" ,
143148 " arn:aws:s3:::local-immunisation-mesh" ,
144149 " arn:aws:s3:::local-immunisation-mesh/*" ,
145150 " arn:aws:s3:::local-immunisation-mesh-s3logs/*"
You can’t perform that action at this time.
0 commit comments