Skip to content

slovink/terraform-azure-vnet

Repository files navigation

Terraform Azure vnet

Terraform module to create vnet on Azure.

Terraform Licence

Table of Contents

Introduction

This repository contains Terraform code to deploy resources on Microsoft Azure, including a resource group and a virtual network.

Usage

You can use this module in your Terraform configuration like this:

The "vnet" module creates an Azure Virtual Network. It references the resource group created by the "vnet" module.

Example: vnet

module "vnet" {
  source              = "git@github.com:slovink/terraform-azure-vnet.git?ref=1.0.0"
  name                = "app"
  environment         = "test"
  resource_group_name = module.resource_group.resource_group_name
  location            = module.resource_group.resource_group_location
  address_space       = "10.0.0.0/16"
 }

Please ensure you specify the correct 'source' path for the module.

Examples

For detailed examples on how to use this module, please refer to the example directory within this repository.

License

This project is licensed under the MIT License - see the LICENSE file for more details.

Author

Your Name Replace MIT and slovink with the appropriate license and your information. Feel free to expand this README with additional details or usage instructions as needed for your specific use case.

Requirements

Name Version
terraform >=1.7.4
azurerm >=3.87.0

Providers

Name Version
azurerm >=3.87.0

Modules

Name Source Version
labels git@github.com:slovink/terraform-azure-labels.git 1.0.0

Resources

Name Type
azurerm_network_ddos_protection_plan.example resource
azurerm_network_watcher.flow_log_nw resource
azurerm_virtual_network.vnet resource

Inputs

Name Description Type Default Required
address_space The address space that is used by the virtual network. string "" no
address_spaces The list of the address spaces that is used by the virtual network. list(string) [] no
bgp_community The BGP community attribute in format :. number null no
dns_servers The DNS servers to be used with vNet. list(string) [] no
edge_zone (Optional) Specifies the Edge Zone within the Azure Region where this Virtual Network should exist. Changing this forces a new Virtual Network to be created. string null no
enable Flag to control the module creation bool true no
enable_ddos_pp Flag to control the resource creation bool false no
enable_network_watcher Flag to control creation of network watcher. bool false no
environment Environment (e.g. prod, dev, staging). string "" no
existing_ddos_pp ID of an existing DDOPS plan defined in the same subscription string null no
flow_timeout_in_minutes The flow timeout in minutes for the Virtual Network, which is used to enable connection tracking for intra-VM flows. Possible values are between 4 and 30 minutes. number 10 no
label_order Label order, e.g. name,application. list(any)
[
"name",
"environment"
]
no
location The location/region where the virtual network is created. Changing this forces a new resource to be created. string "" no
managedby ManagedBy, eg 'slovink'. string "contact@slovink.com" no
name Name (e.g. app or cluster). string "" no
repository Terraform current module repo string "https://github.com/slovink/terraform-azure-vnet" no
resource_group_name The name of the resource group in which to create the virtual network. Changing this forces a new resource to be created. string "" no

Outputs

Name Description
ddos_protection_plan_id The ID of the DDoS Protection Plan
id The id of the newly created vNet
name The name of the newly created vNet
network_watcher_id The ID of the Network Watcher.
network_watcher_name The name of Network Watcher deployed.
vnet_address_space The address space of the newly created vNet
vnet_guid The GUID of the virtual network.
vnet_location The location of the newly created vNet
vnet_rg_name The name of the resource group in which to create the virtual network. Changing this forces a new resource to be created

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published