Skip to content

Commit 3d8d7a8

Browse files
authored
Merge pull request #39 from MITLibraries/dev
Dev-to-Stage: Add ECR Repositories for browsertrix-harvester
2 parents 1774d33 + 1f8a1cc commit 3d8d7a8

File tree

2 files changed

+65
-0
lines changed

2 files changed

+65
-0
lines changed

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ then replace all the ssm parameter references for `oidc_arn` with `aws_iam_openi
8888
| ecr\_ppod | ./modules/ecr | n/a |
8989
| ecr\_sapinvoices | ./modules/ecr | n/a |
9090
| ecr\_slingshot | ./modules/ecr | n/a |
91+
| ecr\_timdex\_broswertrix | ./modules/ecr | n/a |
9192
| ecr\_timdex\_lambdas | ./modules/ecr | n/a |
9293
| ecr\_timdex\_tim | ./modules/ecr | n/a |
9394
| ecr\_timdex\_transmogrifier | ./modules/ecr | n/a |
@@ -123,6 +124,10 @@ then replace all the ssm parameter references for `oidc_arn` with `aws_iam_openi
123124
| alma\_webhook\_lambdas\_makefile | Full contents of the Makefile for the alma-webhook-lambdas repo (allows devs to push to Dev account only) |
124125
| alma\_webhook\_lambdas\_prod\_promote\_workflow | Full contents of the prod-promote.yml for the alma-webhook-lambdas repo |
125126
| alma\_webhook\_lambdas\_stage\_build\_workflow | Full contents of the stage-build.yml for the alma-webhook-lambdas repo |
127+
| broswertrix\_dev\_build\_workflow | Full contents of the dev-build.yml for the browsertrix-harvester repo |
128+
| broswertrix\_makefile | Full contents of the Makefile for the browsertrix-harvester repo (allows devs to push to Dev account only) |
129+
| broswertrix\_prod\_promote\_workflow | Full contents of the prod-promote.yml for the browsertrix-harvester repo |
130+
| broswertrix\_stage\_build\_workflow | Full contents of the stage-build.yml for the browsertrix-harvester repo |
126131
| bursar\_dev\_build\_workflow | Full contents of the dev-build.yml for the alma-bursartransfer repo |
127132
| bursar\_makefile | Full contents of the Makefile for the alma-bursartransfer repo (allows devs to push to Dev account only) |
128133
| bursar\_prod\_promote\_workflow | Full contents of the prod-promote.yml for the alma-bursartransfer repo |

timdex_ecrs.tf

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ output "timdex_lambdas_prod_promote_workflow" {
185185
description = "Full contents of the prod-promote.yml for the timdex-pipeline-lambdas repo"
186186
}
187187

188+
188189
## timdex-index-manager
189190
# timdex-index-manager ECR repository
190191
module "ecr_timdex_tim" {
@@ -242,3 +243,62 @@ output "tim_prod_promote_workflow" {
242243
)
243244
description = "Full contents of the prod-promote.yml for the timdex-index-manager repo"
244245
}
246+
247+
248+
## browsertrix-harvester
249+
# browsertrix-harvester ECR repository
250+
module "ecr_timdex_broswertrix" {
251+
source = "./modules/ecr"
252+
repo_name = "browsertrix-harvester"
253+
login_policy_arn = aws_iam_policy.login.arn
254+
oidc_arn = data.aws_ssm_parameter.oidc_arn.value
255+
environment = var.environment
256+
tfoutput_ssm_path = var.tfoutput_ssm_path
257+
tags = {
258+
app-repo = "timdex-infrastructure-browsertrix"
259+
}
260+
}
261+
# Outputs in dev
262+
output "broswertrix_dev_build_workflow" {
263+
value = var.environment == "prod" || var.environment == "stage" ? null : templatefile("${path.module}/files/dev-build.tpl", {
264+
region = var.aws_region
265+
role = module.ecr_timdex_broswertrix.gha_role
266+
ecr = module.ecr_timdex_broswertrix.repository_name
267+
function = ""
268+
}
269+
)
270+
description = "Full contents of the dev-build.yml for the browsertrix-harvester repo"
271+
}
272+
output "broswertrix_makefile" {
273+
value = var.environment == "prod" || var.environment == "stage" ? null : templatefile("${path.module}/files/makefile.tpl", {
274+
ecr_name = module.ecr_timdex_broswertrix.repository_name
275+
ecr_url = module.ecr_timdex_broswertrix.repository_url
276+
function = ""
277+
}
278+
)
279+
description = "Full contents of the Makefile for the browsertrix-harvester repo (allows devs to push to Dev account only)"
280+
}
281+
# Outputs in stage
282+
output "broswertrix_stage_build_workflow" {
283+
value = var.environment == "prod" || var.environment == "dev" ? null : templatefile("${path.module}/files/stage-build.tpl", {
284+
region = var.aws_region
285+
role = module.ecr_timdex_broswertrix.gha_role
286+
ecr = module.ecr_timdex_broswertrix.repository_name
287+
function = ""
288+
}
289+
)
290+
description = "Full contents of the stage-build.yml for the browsertrix-harvester repo"
291+
}
292+
# Outputs after promotion to prod
293+
output "broswertrix_prod_promote_workflow" {
294+
value = var.environment == "stage" || var.environment == "dev" ? null : templatefile("${path.module}/files/prod-promote.tpl", {
295+
region = var.aws_region
296+
role_stage = "${module.ecr_timdex_broswertrix.repo_name}-gha-stage"
297+
role_prod = "${module.ecr_timdex_broswertrix.repo_name}-gha-prod"
298+
ecr_stage = "${module.ecr_timdex_broswertrix.repo_name}-stage"
299+
ecr_prod = "${module.ecr_timdex_broswertrix.repo_name}-prod"
300+
function = ""
301+
}
302+
)
303+
description = "Full contents of the prod-promote.yml for the browsertrix-harvester repo"
304+
}

0 commit comments

Comments
 (0)