Vnet
A resource of the Azure provider, version 0.3.0, in its Networking group. Import it with:
import Vnet from "azure/networking"Example
resource Vnet example {
name = "example-value"
resourceGroup = "example-value"
location = "example-value"
addressSpaces = "..."
dnsServers = "..."
enableDdosProtection = false
enableVmProtection = false
tags = "..."
}Properties
Set by your code in the resource block. A required one must be set; any other you leave out takes the value under Default, if it has one.
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
name | string | — | No | The name of the virtual network |
resourceGroup | string | — | No | The Azure resource group name |
location | string | — | No | The Azure region/location (e.g., eastus, westeurope) |
addressSpaces | any[] | — | No | The address spaces for the VNet in CIDR notation |
dnsServers | any[] | — | No | Custom DNS servers for the VNet. If not specified, Azure-provided DNS is used |
enableDdosProtection | boolean | false | No | Enable DDoS protection for the VNet |
enableVmProtection | boolean | false | No | Enable VM protection for the VNet |
tags | object | — | No | Tags to apply to the VNet |
Set by Azure after the resource is created: your code can read them but not set them. An importable one identifies an existing resource.
| Name | Type | Importable | Description |
|---|---|---|---|
id | string | Yes | The Azure resource ID of the VNet |
provisioningState | string | No | The provisioning state of the VNet |
resourceGuid | string | No | The resource GUID of the VNet |
hasSubnets | boolean | No | Whether the VNet has any subnets |