forked from GoogleCloudPlatform/cloud-foundation-fabric
-
Notifications
You must be signed in to change notification settings - Fork 0
/
variables.tf
168 lines (156 loc) · 4.84 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
/**
* Copyright 2023 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
variable "iam" {
description = "IAM bindings for topic in {ROLE => [MEMBERS]} format."
type = map(list(string))
default = {}
nullable = false
}
variable "iam_bindings" {
description = "Authoritative IAM bindings in {KEY => {role = ROLE, members = [], condition = {}}}. Keys are arbitrary."
type = map(object({
members = list(string)
role = string
condition = optional(object({
expression = string
title = string
description = optional(string)
}))
}))
nullable = false
default = {}
}
variable "iam_bindings_additive" {
description = "Keyring individual additive IAM bindings. Keys are arbitrary."
type = map(object({
member = string
role = string
condition = optional(object({
expression = string
title = string
description = optional(string)
}))
}))
nullable = false
default = {}
}
variable "kms_key" {
description = "KMS customer managed encryption key."
type = string
default = null
}
variable "labels" {
description = "Labels."
type = map(string)
default = {}
nullable = false
}
variable "message_retention_duration" {
description = "Minimum duration to retain a message after it is published to the topic."
type = string
default = null
}
variable "name" {
description = "PubSub topic name."
type = string
}
variable "project_id" {
description = "Project used for resources."
type = string
}
variable "regions" {
description = "List of regions used to set persistence policy."
type = list(string)
default = []
nullable = false
}
variable "schema" {
description = "Topic schema. If set, all messages in this topic should follow this schema."
type = object({
definition = string
msg_encoding = optional(string, "ENCODING_UNSPECIFIED")
schema_type = string
})
default = null
}
variable "subscriptions" {
description = "Topic subscriptions. Also define push configs for push subscriptions. If options is set to null subscription defaults will be used. Labels default to topic labels if set to null."
type = map(object({
labels = optional(map(string))
ack_deadline_seconds = optional(number)
message_retention_duration = optional(string)
retain_acked_messages = optional(bool, false)
expiration_policy_ttl = optional(string)
filter = optional(string)
enable_message_ordering = optional(bool, false)
enable_exactly_once_delivery = optional(bool, false)
dead_letter_policy = optional(object({
topic = string
max_delivery_attempts = optional(number)
}))
retry_policy = optional(object({
minimum_backoff = optional(number)
maximum_backoff = optional(number)
}))
bigquery = optional(object({
table = string
use_table_schema = optional(bool, false)
use_topic_schema = optional(bool, false)
write_metadata = optional(bool, false)
drop_unknown_fields = optional(bool, false)
}))
cloud_storage = optional(object({
bucket = string
filename_prefix = optional(string)
filename_suffix = optional(string)
max_duration = optional(string)
max_bytes = optional(number)
avro_config = optional(object({
write_metadata = optional(bool, false)
}))
}))
push = optional(object({
endpoint = string
attributes = optional(map(string))
no_wrapper = optional(bool, false)
oidc_token = optional(object({
audience = optional(string)
service_account_email = string
}))
}))
iam = optional(map(list(string)), {})
iam_bindings = optional(map(object({
members = list(string)
role = string
condition = optional(object({
expression = string
title = string
description = optional(string)
}))
})), {})
iam_bindings_additive = optional(map(object({
member = string
role = string
condition = optional(object({
expression = string
title = string
description = optional(string)
}))
})), {})
}))
default = {}
nullable = false
}