Skip to content

Commit d97ec14

Browse files
authored
doc: Gobal deny doc update (#490)
1 parent e902247 commit d97ec14

File tree

2 files changed

+40
-8
lines changed

2 files changed

+40
-8
lines changed

examples/fscloud/main.tf

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,24 +70,31 @@ module "cbr_account_level" {
7070

7171
## Enable enforcement for key protect as an example
7272
## The other services not referenced here, are either report, or disabled (when not support report)
73+
## When a scope is specified in a rule for the target service, a new separate global rule will be created for the respective target service to scope all the resources of that service. This can be opted out by setting the variable 'global_deny = false'
74+
## It is mandatory to set 'global_deny = false' when no scope is specified for the target service
75+
7376
target_service_details = {
7477
# Using 'kms' for Key Protect value as target service name supported by CBR for Key Protect is 'kms'.
7578
"kms" = {
7679
# Demonstrates how a customized CBR description (also seen as being the rule name) can be set
7780
"description" = "kms-rule-example-of-customized-description"
7881
"enforcement_mode" = "enabled"
7982
"instance_id" = module.key_protect_module.key_protect_guid
80-
"global_deny" = false
8183
"target_rg" = module.resource_group.resource_group_id
84+
"global_deny" = false # opting out from creating a new global rule
8285
}
8386
"cloud-object-storage" = {
87+
"enforcement_mode" = "enabled"
88+
"global_deny" = false # mandatory to set 'global_deny = false' when no scope is defined
89+
}
90+
"messagehub" = {
91+
# As the service is scoped, a new global rule will also get created
8492
"enforcement_mode" = "enabled"
8593
"target_rg" = module.resource_group.resource_group_id
86-
"global_deny" = false
8794
}
8895
"mqcloud" : {
89-
"enforcement_mode" = "disabled"
90-
"region" = "eu-fr2" # BNPP region (region or serviceInstance is/are required for service 'mqcloud`)
96+
"enforcement_mode" = "enabled"
97+
"region" = "eu-fr2" # region and/or instance_id is/are required for service 'mqcloud'
9198
"global_deny" = false
9299
}
93100
"IAM" : {

modules/fscloud/README.md

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ Important: In order to avoid unexpected breakage in the account against which th
2626

2727
**Note on Event Notifications**: Event Notifications introduced SMTP API that does not support `report` enforcement mode. By default `report` mode is set which excludes SMTP API. If enforcement mode is set to `enabled`, CBR will be applied to the SMTP API as well.
2828

29+
**Note on global_deny variable**: When a `scope` is specified in a rule for the target service, a new separate `global rule` will be created for the respective target service to scope `all the resources` of that service. This can be opted out by setting the variable `global_deny = false`. It is also mandatory to set `global_deny = false` when no scope is specified for the target service.
30+
31+
**Note on `mqcloud`**: Region and/or instance_id is/are required for service `mqcloud` to create the CBR rule.
32+
2933
## Note
3034
The services 'directlink', 'globalcatalog-collection', 'iam-groups' and 'user-management' do not support restriction per location.
3135

@@ -51,10 +55,31 @@ module "cbr_fscloud" {
5155
# Will skip the zone creation for service ref. present in the list
5256
skip_specific_services_for_zone_creation = ["user-management", "iam-groups"]
5357
54-
target_service_details = {
55-
"kms" = {
56-
"enforcement_mode" = "enabled"
57-
}}
58+
target_service_details = {
59+
"kms" = {
60+
"enforcement_mode" = "enabled"
61+
"instance_id" = "dhd2-2bdjd-2bdjd-asgd3" # pragma: allowlist secret
62+
"target_rg" = "a8cff104f1764e98aac9ab879198230a" # pragma: allowlist secret
63+
}
64+
"cloud-object-storage" = {
65+
"enforcement_mode" = "enabled"
66+
"target_rg" = "a8cff104f1764e98aac9ab879198230a" # pragma: allowlist secret
67+
"global_deny" = false # opting out from creating a new global rule
68+
}
69+
"messagehub" = {
70+
"enforcement_mode" = "enabled"
71+
"global_deny" = false # mandatory to set 'global_deny = false' when no scope is defined
72+
}
73+
"mqcloud" : {
74+
"enforcement_mode" = "enabled"
75+
"region" = "eu-fr2" # region and/or instance_id is/are required for service 'mqcloud'
76+
"global_deny" = false
77+
}
78+
"IAM" : {
79+
"enforcement_mode" = "report"
80+
"global_deny" = false
81+
}
82+
}
5883
5984
custom_rule_contexts_by_service = {
6085
"schematics" = [{

0 commit comments

Comments
 (0)