Skip to content

Commit 6606d38

Browse files
committed
SUMO-192150: first edit of "monitor_folder.html.markdown"
1 parent 57eef32 commit 6606d38

File tree

1 file changed

+46
-2
lines changed

1 file changed

+46
-2
lines changed

website/docs/r/monitor_folder.html.markdown

Lines changed: 46 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,32 @@ resource "sumologic_monitor_folder" "tf_monitor_folder_1" {
2424

2525
## Example Nested Monitor Folders
2626

27-
NOTE: Monitor folders allow up to six (6) levels of sub-folders.
27+
NOTE:
28+
- Monitor folders allow up to six (6) levels of sub-folders.
29+
- `obj_permission` are added at one of the Folders to showcase how Fine Grain Permissions (FGP) are associated with two roles.
30+
2831

2932
```hcl
33+
resource "sumologic_role" "tf_test_role_01" {
34+
name = "tf_test_role_01"
35+
description = "Testing resource sumologic_role"
36+
capabilities = [
37+
"viewAlerts",
38+
"viewMonitorsV2",
39+
"manageMonitorsV2"
40+
]
41+
}
42+
43+
resource "sumologic_role" "tf_test_role_02" {
44+
name = "tf_test_role_02"
45+
description = "Testing resource sumologic_role"
46+
capabilities = [
47+
"viewAlerts",
48+
"viewMonitorsV2",
49+
"manageMonitorsV2"
50+
]
51+
}
52+
3053
resource "sumologic_monitor_folder" "tf_security_team_root_folder" {
3154
name = "Security Team Monitors"
3255
description = "Monitors used by the Security Team."
@@ -36,6 +59,16 @@ resource "sumologic_monitor_folder" "tf_security_team_prod_folder" {
3659
name = "Production Monitors"
3760
description = "Monitors for the Security Team Production Environment."
3861
parent_id = sumologic_monitor_folder.tf_security_team_root_folder.id
62+
obj_permission {
63+
subject_type = "role"
64+
subject_id = sumologic_role.tf_test_role_01.id
65+
permissions = ["Create","Read","Update"]
66+
}
67+
obj_permission {
68+
subject_type = "role"
69+
subject_id = sumologic_role.tf_test_role_02.id
70+
permissions = ["Create", "Read"]
71+
}
3972
}
4073
4174
resource "sumologic_monitor_folder" "tf_security_team_stag_folder" {
@@ -53,7 +86,18 @@ The following arguments are supported:
5386
- `name` - (Required) The name of the monitor folder. The name must be alphanumeric.
5487
- `description` - (Required) The description of the monitor folder.
5588
- `parent_id` - (Optional) The identifier of the Monitor Folder that contains this Monitor Folder. Defaults to the root folder.
56-
89+
- `obj_permission` - (Optional) `obj_permission` construct represents a Permission Statement associated with this Folder. A set of `obj_permission` constructs can be specified under a single Folder. An `obj_permission` construct can be used to control permissions Explicitly associated with a Folder. But, it cannot be used to control permissions Inherited from a Parent / Ancestor Folder. Default FGP would be still set to the Folder upon creation (e.g. the creating user would have full permission), even if no `obj_permission` construct is specified at a Folder and the FGP feature is enabled at the account.
90+
- `subject_type` - (Required) Valid values:
91+
- `role`
92+
- `org`
93+
- `subject_id` - (Required) A Role ID or the Org ID of the account
94+
- `permissions` - (Required) A Set of Permissions. Valid Permission Values:
95+
- `Create`
96+
- `Read`
97+
- `Update`
98+
- `Delete`
99+
- `Manage`
100+
57101
Additional data provided in state:
58102

59103
- `id` - (Computed) The identifier for this monitor folder.

0 commit comments

Comments
 (0)