azurermSubnetServiceEndpointStoragePolicy
Manages a Subnet Service Endpoint Storage Policy.
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: "example-rg",
}
);
const azurermStorageAccountExample = new azurerm.storageAccount.StorageAccount(
this,
"example_1",
{
account_replication_type: "GRS",
account_tier: "Standard",
location: azurermResourceGroupExample.location,
name: "examplestorageacct",
resource_group_name: azurermResourceGroupExample.name,
}
);
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
azurermStorageAccountExample.overrideLogicalId("example");
const azurermSubnetServiceEndpointStoragePolicyExample =
new azurerm.subnetServiceEndpointStoragePolicy.SubnetServiceEndpointStoragePolicy(
this,
"example_2",
{
definition: [
{
description: "definition1",
name: "name1",
service_resources: [
azurermResourceGroupExample.id,
azurermStorageAccountExample.id,
],
},
],
location: azurermResourceGroupExample.location,
name: "example-policy",
resource_group_name: azurermResourceGroupExample.name,
}
);
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
azurermSubnetServiceEndpointStoragePolicyExample.overrideLogicalId("example");
Arguments Reference
The following arguments are supported:
-
name
- (Required) The name which should be used for this Subnet Service Endpoint Storage Policy. Changing this forces a new Subnet Service Endpoint Storage Policy to be created. -
resourceGroupName
- (Required) The name of the Resource Group where the Subnet Service Endpoint Storage Policy should exist. Changing this forces a new Subnet Service Endpoint Storage Policy to be created. -
location
- (Required) The Azure Region where the Subnet Service Endpoint Storage Policy should exist. Changing this forces a new Subnet Service Endpoint Storage Policy to be created.
-
definition
- (Optional) Adefinition
block as defined below -
tags
- (Optional) A mapping of tags which should be assigned to the Subnet Service Endpoint Storage Policy.
A definition
block supports the following:
-
name
- (Required) The name which should be used for this Subnet Service Endpoint Storage Policy Definition. -
serviceResources
- (Required) Specifies a list of resources that this Subnet Service Endpoint Storage Policy Definition applies to. -
description
- (Optional) The description of this Subnet Service Endpoint Storage Policy Definition.
Attributes Reference
In addition to the Arguments listed above - the following Attributes are exported:
id
- The ID of the Subnet Service Endpoint Storage Policy.
Timeouts
The timeouts
block allows you to specify timeouts for certain actions:
create
- (Defaults to 30 minutes) Used when creating the Subnet Service Endpoint Storage Policy.read
- (Defaults to 5 minutes) Used when retrieving the Subnet Service Endpoint Storage Policy.update
- (Defaults to 30 minutes) Used when updating the Subnet Service Endpoint Storage Policy.delete
- (Defaults to 30 minutes) Used when deleting the Subnet Service Endpoint Storage Policy.
Import
Subnet Service Endpoint Policies can be imported using the resourceId
, e.g.