generated from clowdhaus/terraform-aws-module-template
-
-
Notifications
You must be signed in to change notification settings - Fork 111
/
variables.tf
199 lines (164 loc) · 6.52 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
variable "create" {
description = "Determines whether resources will be created (affects all resources)"
type = bool
default = true
}
variable "tags" {
description = "A map of tags to add to all resources"
type = map(string)
default = {}
}
variable "repository_type" {
description = "The type of repository to create. Either `public` or `private`"
type = string
default = "private"
}
################################################################################
# Repository
################################################################################
variable "create_repository" {
description = "Determines whether a repository will be created"
type = bool
default = true
}
variable "repository_name" {
description = "The name of the repository"
type = string
default = ""
}
variable "repository_image_tag_mutability" {
description = "The tag mutability setting for the repository. Must be one of: `MUTABLE` or `IMMUTABLE`. Defaults to `IMMUTABLE`"
type = string
default = "IMMUTABLE"
}
variable "repository_encryption_type" {
description = "The encryption type for the repository. Must be one of: `KMS` or `AES256`. Defaults to `AES256`"
type = string
default = null
}
variable "repository_kms_key" {
description = "The ARN of the KMS key to use when encryption_type is `KMS`. If not specified, uses the default AWS managed key for ECR"
type = string
default = null
}
variable "repository_image_scan_on_push" {
description = "Indicates whether images are scanned after being pushed to the repository (`true`) or not scanned (`false`)"
type = bool
default = true
}
variable "repository_policy" {
description = "The JSON policy to apply to the repository. If not specified, uses the default policy"
type = string
default = null
}
variable "repository_force_delete" {
description = "If `true`, will delete the repository even if it contains images. Defaults to `false`"
type = bool
default = null
}
################################################################################
# Repository Policy
################################################################################
variable "attach_repository_policy" {
description = "Determines whether a repository policy will be attached to the repository"
type = bool
default = true
}
variable "create_repository_policy" {
description = "Determines whether a repository policy will be created"
type = bool
default = true
}
variable "repository_read_access_arns" {
description = "The ARNs of the IAM users/roles that have read access to the repository"
type = list(string)
default = []
}
variable "repository_lambda_read_access_arns" {
description = "The ARNs of the Lambda service roles that have read access to the repository"
type = list(string)
default = []
}
variable "repository_read_write_access_arns" {
description = "The ARNs of the IAM users/roles that have read/write access to the repository"
type = list(string)
default = []
}
variable "repository_policy_statements" {
description = "A map of IAM policy [statements](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document#statement) for custom permission usage"
type = any
default = {}
}
################################################################################
# Lifecycle Policy
################################################################################
variable "create_lifecycle_policy" {
description = "Determines whether a lifecycle policy will be created"
type = bool
default = true
}
variable "repository_lifecycle_policy" {
description = "The policy document. This is a JSON formatted string. See more details about [Policy Parameters](http://docs.aws.amazon.com/AmazonECR/latest/userguide/LifecyclePolicies.html#lifecycle_policy_parameters) in the official AWS docs"
type = string
default = ""
}
################################################################################
# Public Repository
################################################################################
variable "public_repository_catalog_data" {
description = "Catalog data configuration for the repository"
type = any
default = {}
}
################################################################################
# Registry Policy
################################################################################
variable "create_registry_policy" {
description = "Determines whether a registry policy will be created"
type = bool
default = false
}
variable "registry_policy" {
description = "The policy document. This is a JSON formatted string"
type = string
default = null
}
################################################################################
# Registry Pull Through Cache Rule
################################################################################
variable "registry_pull_through_cache_rules" {
description = "List of pull through cache rules to create"
type = map(map(string))
default = {}
}
################################################################################
# Registry Scanning Configuration
################################################################################
variable "manage_registry_scanning_configuration" {
description = "Determines whether the registry scanning configuration will be managed"
type = bool
default = false
}
variable "registry_scan_type" {
description = "the scanning type to set for the registry. Can be either `ENHANCED` or `BASIC`"
type = string
default = "ENHANCED"
}
variable "registry_scan_rules" {
description = "One or multiple blocks specifying scanning rules to determine which repository filters are used and at what frequency scanning will occur"
type = any
default = []
}
################################################################################
# Registry Replication Configuration
################################################################################
variable "create_registry_replication_configuration" {
description = "Determines whether a registry replication configuration will be created"
type = bool
default = false
}
variable "registry_replication_rules" {
description = "The replication rules for a replication configuration. A maximum of 10 are allowed"
type = any
default = []
}