Skip to content

Commit 20b6a30

Browse files
authored
fix: Change exclusion variables in submodules to accept sets (#44)
1 parent 61cd430 commit 20b6a30

File tree

8 files changed

+32
-32
lines changed

8 files changed

+32
-32
lines changed

modules/bucket_policy_only/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ This Terraform module allows to set a `Uniform Bucket-level Access` [Organizatio
77

88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
10-
| exclude\_folders | List of folders to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
11-
| exclude\_projects | List of projects to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
10+
| exclude\_folders | Set of folders to exclude from the policy | `set(string)` | `[]` | no |
11+
| exclude\_projects | Set of projects to exclude from the policy | `set(string)` | `[]` | no |
1212
| folder\_id | The folder id for putting the policy | `string` | `null` | no |
1313
| organization\_id | The organization id for putting the policy | `string` | `null` | no |
1414
| policy\_for | Resource hierarchy node to apply the policy to: can be one of `organization`, `folder`, or `project`. | `string` | n/a | yes |

modules/bucket_policy_only/variables.tf

+6-6
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@ variable "project_id" {
3838
}
3939

4040
variable "exclude_folders" {
41-
description = "List of folders to exclude from the policy"
42-
type = list(string)
43-
default = [""]
41+
description = "Set of folders to exclude from the policy"
42+
type = set(string)
43+
default = []
4444
}
4545

4646
variable "exclude_projects" {
47-
description = "List of projects to exclude from the policy"
48-
type = list(string)
49-
default = [""]
47+
description = "Set of projects to exclude from the policy"
48+
type = set(string)
49+
default = []
5050
}

modules/domain_restricted_sharing/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ This Terraform module allows to set a `Domain Restricted Sharing` [Organization
88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
1010
| domains\_to\_allow | The list of domains to allow users from | `list(string)` | n/a | yes |
11-
| exclude\_folders | List of folders to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
12-
| exclude\_projects | List of projects to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
11+
| exclude\_folders | Set of folders to exclude from the policy | `set(string)` | `[]` | no |
12+
| exclude\_projects | Set of projects to exclude from the policy | `set(string)` | `[]` | no |
1313
| folder\_id | The folder id for putting the policy | `string` | `null` | no |
1414
| organization\_id | The organization id for putting the policy | `string` | `null` | no |
1515
| policy\_for | Resource hierarchy node to apply the policy to: can be one of `organization`, `folder`, or `project`. | `string` | n/a | yes |

modules/domain_restricted_sharing/variables.tf

+6-6
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ variable "domains_to_allow" {
4343
}
4444

4545
variable "exclude_folders" {
46-
description = "List of folders to exclude from the policy"
47-
type = list(string)
48-
default = [""]
46+
description = "Set of folders to exclude from the policy"
47+
type = set(string)
48+
default = []
4949
}
5050

5151
variable "exclude_projects" {
52-
description = "List of projects to exclude from the policy"
53-
type = list(string)
54-
default = [""]
52+
description = "Set of projects to exclude from the policy"
53+
type = set(string)
54+
default = []
5555
}

modules/restrict_vm_external_ips/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ This Terraform module allows to set an `Allowed External IPs for VM instances` [
77

88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
10-
| exclude\_folders | List of folders to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
11-
| exclude\_projects | List of projects to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
10+
| exclude\_folders | Set of folders to exclude from the policy | `set(string)` | `[]` | no |
11+
| exclude\_projects | Set of projects to exclude from the policy | `set(string)` | `[]` | no |
1212
| folder\_id | The folder id for putting the policy | `string` | `null` | no |
1313
| organization\_id | The organization id for putting the policy | `string` | `null` | no |
1414
| policy\_for | Resource hierarchy node to apply the policy to: can be one of `organization`, `folder`, or `project`. | `string` | n/a | yes |

modules/restrict_vm_external_ips/variables.tf

+6-6
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,13 @@ variable "vms_to_allow" {
4444
}
4545

4646
variable "exclude_folders" {
47-
description = "List of folders to exclude from the policy"
48-
type = list(string)
49-
default = [""]
47+
description = "Set of folders to exclude from the policy"
48+
type = set(string)
49+
default = []
5050
}
5151

5252
variable "exclude_projects" {
53-
description = "List of projects to exclude from the policy"
54-
type = list(string)
55-
default = [""]
53+
description = "Set of projects to exclude from the policy"
54+
type = set(string)
55+
default = []
5656
}

modules/skip_default_network/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ This Terraform module allows to set a `Skip Default Network Creation` [Organizat
77

88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
10-
| exclude\_folders | List of folders to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
11-
| exclude\_projects | List of projects to exclude from the policy | `list(string)` | <pre>[<br> ""<br>]</pre> | no |
10+
| exclude\_folders | Set of folders to exclude from the policy | `set(string)` | `[]` | no |
11+
| exclude\_projects | Set of projects to exclude from the policy | `set(string)` | `[]` | no |
1212
| folder\_id | The folder id for putting the policy | `string` | `null` | no |
1313
| organization\_id | The organization id for putting the policy | `string` | `null` | no |
1414
| policy\_for | Resource hierarchy node to apply the policy to: can be one of `organization`, `folder`, or `project`. | `string` | n/a | yes |

modules/skip_default_network/variables.tf

+6-6
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,13 @@ variable "project_id" {
3838
}
3939

4040
variable "exclude_folders" {
41-
description = "List of folders to exclude from the policy"
42-
type = list(string)
43-
default = [""]
41+
description = "Set of folders to exclude from the policy"
42+
type = set(string)
43+
default = []
4444
}
4545

4646
variable "exclude_projects" {
47-
description = "List of projects to exclude from the policy"
48-
type = list(string)
49-
default = [""]
47+
description = "Set of projects to exclude from the policy"
48+
type = set(string)
49+
default = []
5050
}

0 commit comments

Comments
 (0)