azurermSecurityCenterWorkspace
Manages the subscription's Security Center Workspace.
\~> NOTE: Owner access permission is required.
Example Usage
/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as azurerm from "./.gen/providers/azurerm";
/*The following providers are missing schema information and might need manual adjustments to synthesize correctly: azurerm.
For a more precise conversion please use the --provider flag in convert.*/
const azurermResourceGroupExample = new azurerm.resourceGroup.ResourceGroup(
this,
"example",
{
location: "West Europe",
name: "tfex-security-workspace",
}
);
const azurermLogAnalyticsWorkspaceExample =
new azurerm.logAnalyticsWorkspace.LogAnalyticsWorkspace(this, "example_1", {
location: azurermResourceGroupExample.location,
name: "tfex-security-workspace",
resource_group_name: azurermResourceGroupExample.name,
sku: "PerGB2018",
});
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
azurermLogAnalyticsWorkspaceExample.overrideLogicalId("example");
const azurermSecurityCenterWorkspaceExample =
new azurerm.securityCenterWorkspace.SecurityCenterWorkspace(
this,
"example_2",
{
scope: "/subscriptions/00000000-0000-0000-0000-000000000000",
workspace_id: azurermLogAnalyticsWorkspaceExample.id,
}
);
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
azurermSecurityCenterWorkspaceExample.overrideLogicalId("example");
Argument Reference
The following arguments are supported:
-
scope
- (Required) The scope of VMs to send their security data to the desired workspace, unless overridden by a setting with more specific scope. -
workspaceId
- (Required) The ID of the Log Analytics Workspace to save the data in.
Attributes Reference
The following attributes are exported:
id
- The Security Center Workspace ID.
Timeouts
The timeouts
block allows you to specify timeouts for certain actions:
create
- (Defaults to 60 minutes) Used when creating the Security Center Workspace.update
- (Defaults to 60 minutes) Used when updating the Security Center Workspace.read
- (Defaults to 5 minutes) Used when retrieving the Security Center Workspace.delete
- (Defaults to 60 minutes) Used when deleting the Security Center Workspace.
Import
The contact can be imported using the resourceId
, e.g.