Skip to content

Commit f4d0bc3

Browse files
authored
Merge pull request #33 from using-system/features/fix-checkov-issues
Features/fix checkov issues
2 parents e5a6fa7 + 45550ce commit f4d0bc3

File tree

40 files changed

+87
-64
lines changed

40 files changed

+87
-64
lines changed

github/actions/checkov/entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ if [ ! -f $1/checkov.yml ]; then
44
cp /config_empty.yml $1/checkov.yml
55
fi
66

7-
checkov -d $1 --config-file $1/checkov.yml
7+
checkov -d $1 --config-file $1/checkov.yml -o github_failed_only

terraform/modules/az-aca/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ No requirements.
77

88
| Name | Version |
99
|------|---------|
10-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.78.0 |
10+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.82.0 |
1111

1212
## Modules
1313

terraform/modules/az-acae-storage/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ No requirements.
77

88
| Name | Version |
99
|------|---------|
10-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.78.0 |
10+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.82.0 |
1111

1212
## Modules
1313

terraform/modules/az-acae/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ No requirements.
77

88
| Name | Version |
99
|------|---------|
10-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.78.0 |
10+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.82.0 |
1111

1212
## Modules
1313

terraform/modules/az-acr/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ No requirements.
77

88
| Name | Version |
99
|------|---------|
10-
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.78.0 |
10+
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.82.0 |
1111

1212
## Modules
1313

@@ -40,6 +40,7 @@ No modules.
4040
| <a name="input_sku"></a> [sku](#input\_sku) | The SKU name of the container registry. | `string` | `"Premium"` | no |
4141
| <a name="input_tags"></a> [tags](#input\_tags) | Tags to associate with resources. | `map(string)` | n/a | yes |
4242
| <a name="input_trust_policy_enabled"></a> [trust\_policy\_enabled](#input\_trust\_policy\_enabled) | Determines if the trust policy is enabled | `bool` | `true` | no |
43+
| <a name="input_zone_redundancy_enabled"></a> [zone\_redundancy\_enabled](#input\_zone\_redundancy\_enabled) | Determines if the zone redundancy is enabled | `bool` | `true` | no |
4344

4445
## Outputs
4546

terraform/modules/az-acr/main.tf

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,13 @@ resource "azurerm_container_registry" "acr" {
2121
for_each = var.georeplication_locations
2222

2323
content {
24-
location = georeplications.value
24+
location = georeplications.value
25+
zone_redundancy_enabled = true
2526
}
2627
}
2728

29+
zone_redundancy_enabled = var.zone_redundancy_enabled
30+
2831
identity {
2932
type = var.identity_type
3033
identity_ids = var.identity_ids

terraform/modules/az-acr/tests/acr_not_secure.tftest.hcl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ run "plan" {
2525
trust_policy_enabled = false
2626
retention_policy_enabled = false
2727
enable_lock_on_acr = false
28+
zone_redundancy_enabled = false
2829
network_rule_bypass_option = "AzureServices"
2930

3031
tags = { Environment = "Test" }
@@ -105,6 +106,11 @@ run "plan" {
105106
error_message = "acr georeplications must be empty"
106107
}
107108

109+
assert {
110+
condition = azurerm_container_registry.acr.zone_redundancy_enabled == false
111+
error_message = "acr zone_redundancy_enabled must be set to true"
112+
}
113+
108114
assert {
109115
condition = length(azurerm_container_registry.acr.tags) == 1
110116
error_message = "acr tags must contains one element"
@@ -133,6 +139,7 @@ run "apply" {
133139
trust_policy_enabled = false
134140
retention_policy_enabled = false
135141
enable_lock_on_acr = false
142+
zone_redundancy_enabled = false
136143
network_rule_bypass_option = "AzureServices"
137144

138145
tags = { Environment = "Test" }

terraform/modules/az-acr/tests/acr_secure.tftest.hcl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,11 @@ run "plan" {
101101
error_message = "acr georeplications must be empty"
102102
}
103103

104+
assert {
105+
condition = azurerm_container_registry.acr.zone_redundancy_enabled == true
106+
error_message = "acr zone_redundancy_enabled must be set to true"
107+
}
108+
104109
assert {
105110
condition = length(azurerm_container_registry.acr.tags) == 1
106111
error_message = "acr tags must contains one element"

terraform/modules/az-acr/variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,12 @@ variable "trust_policy_enabled" {
6969
default = true
7070
}
7171

72+
variable "zone_redundancy_enabled" {
73+
description = "Determines if the zone redundancy is enabled"
74+
type = bool
75+
default = true
76+
}
77+
7278
variable "identity_type" {
7379
description = "The type of identity used for the acr."
7480
type = string

terraform/modules/az-ad-security-group-members/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ No requirements.
77

88
| Name | Version |
99
|------|---------|
10-
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.45.0 |
10+
| <a name="provider_azuread"></a> [azuread](#provider\_azuread) | 2.46.0 |
1111

1212
## Modules
1313

0 commit comments

Comments
 (0)