Skip to content

Commit 8b186a1

Browse files
feat: add ecr replication_configurations variable (#20)
* feat: add ecr replication configurations variable * formatting
1 parent fd720c9 commit 8b186a1

File tree

3 files changed

+32
-17
lines changed

3 files changed

+32
-17
lines changed

README.md

Lines changed: 13 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.tf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ locals {
2424

2525
module "ecr" {
2626
source = "cloudposse/ecr/aws"
27-
version = "0.36.0"
27+
version = "0.41.0"
2828

2929
protected_tags = var.protected_tags
3030
enable_lifecycle_policy = var.enable_lifecycle_policy
@@ -36,6 +36,7 @@ module "ecr" {
3636
principals_lambda = var.principals_lambda
3737
scan_images_on_push = var.scan_images_on_push
3838
use_fullname = false
39+
replication_configurations = var.replication_configurations
3940

4041
context = module.this.context
4142
}

src/variables.tf

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,20 @@ variable "pull_through_cache_rules" {
6767
description = "Map of pull through cache rules to configure"
6868
default = {}
6969
}
70+
71+
variable "replication_configurations" {
72+
type = list(object({
73+
rules = list(object({
74+
destinations = list(object({
75+
region = string
76+
registry_id = string
77+
}))
78+
repository_filters = list(object({
79+
filter = string
80+
filter_type = string
81+
}))
82+
}))
83+
}))
84+
description = "Replication configuration for a registry. See [Replication Configuration](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/ecr_replication_configuration#replication-configuration)."
85+
default = []
86+
}

0 commit comments

Comments
 (0)