Add oauth proxy and supporting ecr infra
This commit is contained in:
parent
675edad612
commit
bd1c17b09b
11 changed files with 222 additions and 2 deletions
33
terraform/ecr.tf
Normal file
33
terraform/ecr.tf
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
resource "aws_ecr_repository" "dumpnet" {
|
||||
name = "dumpnet/mcp-auth-proxy"
|
||||
image_tag_mutability = "MUTABLE"
|
||||
|
||||
image_scanning_configuration {
|
||||
scan_on_push = true
|
||||
}
|
||||
|
||||
encryption_configuration {
|
||||
encryption_type = "AES256"
|
||||
}
|
||||
}
|
||||
|
||||
resource "aws_ecr_lifecycle_policy" "dumpnet" {
|
||||
repository = aws_ecr_repository.dumpnet.name
|
||||
|
||||
policy = jsonencode({
|
||||
rules = [{
|
||||
rulePriority = 1
|
||||
description = "Keep last 5 images per tag prefix"
|
||||
selection = {
|
||||
tagStatus = "any"
|
||||
countType = "imageCountMoreThan"
|
||||
countNumber = 5
|
||||
}
|
||||
action = { type = "expire" }
|
||||
}]
|
||||
})
|
||||
}
|
||||
|
||||
output "ecr_registry" {
|
||||
value = aws_ecr_repository.dumpnet.repository_url
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue