-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from quantum-sec/revert-3-feature/XDR-4570
Revert "XDR-4570: Remove inutile terraform package module"
- Loading branch information
Showing
3 changed files
with
102 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<!-- BEGIN_TF_DOCS --> | ||
## Requirements | ||
|
||
| Name | Version | | ||
|------|---------| | ||
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | >= 1.2 | | ||
| <a name="requirement_null"></a> [null](#requirement\_null) | ~> 3.2.1 | | ||
| <a name="requirement_template"></a> [template](#requirement\_template) | ~> 2.2.0 | | ||
|
||
## Modules | ||
|
||
| Name | Source | Version | | ||
|------|--------|---------| | ||
| <a name="module_custom_sentinel_workbooks"></a> [custom\_sentinel\_workbooks](#module\_custom\_sentinel\_workbooks) | ../sentinel-workbook | n/a | | ||
| <a name="module_sentinel_workbooks"></a> [sentinel\_workbooks](#module\_sentinel\_workbooks) | ../sentinel-workbook | n/a | | ||
|
||
## Inputs | ||
|
||
| Name | Description | Type | Default | Required | | ||
|------|-------------|------|---------|:--------:| | ||
| <a name="input_default_workbook_path"></a> [default\_workbook\_path](#input\_default\_workbook\_path) | The path of the default workbooks. | `string` | n/a | yes | | ||
| <a name="input_resource_group_name"></a> [resource\_group\_name](#input\_resource\_group\_name) | The name of the resource group in which this resource will be provisioned. | `string` | n/a | yes | | ||
| <a name="input_workbook_source_id"></a> [workbook\_source\_id](#input\_workbook\_source\_id) | The resource id of log analytics workspace on which the workbook will be deployed. | `string` | n/a | yes | | ||
| <a name="input_custom_workbook_path"></a> [custom\_workbook\_path](#input\_custom\_workbook\_path) | The path of the custom workbooks. | `string` | `""` | no | | ||
| <a name="input_custom_workbooks"></a> [custom\_workbooks](#input\_custom\_workbooks) | A list of custom workbooks to be deployed from the custom-workbooks folder. | `set(string)` | `[]` | no | | ||
| <a name="input_default_workbooks"></a> [default\_workbooks](#input\_default\_workbooks) | A list of default workbooks to be deployed. | `set(string)` | `[]` | no | | ||
<!-- END_TF_DOCS --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
terraform { | ||
required_version = ">= 1.2" | ||
|
||
required_providers { | ||
null = { | ||
source = "hashicorp/null" | ||
version = "~> 3.2.1" | ||
} | ||
|
||
template = { | ||
source = "hashicorp/template" | ||
version = "~> 2.2.0" | ||
} | ||
} | ||
} | ||
|
||
# Deploy default workbooks | ||
module "sentinel_workbooks" { | ||
source = "../sentinel-workbook" | ||
|
||
for_each = var.default_workbooks | ||
|
||
content_path_workbooks = var.default_workbook_path | ||
workbook_source_id = var.workbook_source_id | ||
name = replace(basename(each.value), ".json", "") | ||
resource_group_name = var.resource_group_name | ||
} | ||
|
||
# Deploy custom workbooks | ||
module "custom_sentinel_workbooks" { | ||
source = "../sentinel-workbook" | ||
|
||
for_each = var.custom_workbooks | ||
|
||
content_path_workbooks = var.custom_workbook_path | ||
workbook_source_id = var.workbook_source_id | ||
name = replace(basename(each.value), ".json", "") | ||
resource_group_name = var.resource_group_name | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# --------------------------------------------------------------------------------------------------------------------- | ||
# MODULE VARIABLES | ||
# --------------------------------------------------------------------------------------------------------------------- | ||
|
||
variable "workbook_source_id" { | ||
description = "The resource id of log analytics workspace on which the workbook will be deployed." | ||
type = string | ||
} | ||
|
||
variable "resource_group_name" { | ||
description = "The name of the resource group in which this resource will be provisioned." | ||
type = string | ||
} | ||
|
||
variable "default_workbooks" { | ||
type = set(string) | ||
default = [] | ||
description = "A list of default workbooks to be deployed." | ||
} | ||
|
||
variable "custom_workbooks" { | ||
type = set(string) | ||
default = [] | ||
description = "A list of custom workbooks to be deployed from the custom-workbooks folder." | ||
} | ||
|
||
variable "custom_workbook_path" { | ||
description = "The path of the custom workbooks." | ||
type = string | ||
default = "" | ||
} | ||
|
||
variable "default_workbook_path" { | ||
description = "The path of the default workbooks." | ||
type = string | ||
} |