Skip to content
This repository is currently being migrated. It's locked while the migration is in progress.

evry/tf-module-azure-application-gateway

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Azure module to create Application Gateway

This modules creates an Application Gateway with the needed resources

Resources created when using this module

  • Resource group (optional, see usage examples)
  • Subnet
  • Public IP address
  • Application Gateway

Using this module

Inputs

Name Description Type Default Required
app_gw_backend_port The port to be assigned to the APP GW backend string 80 no
app_gw_backend_protocol Valid values are: http and https string http no
app_gw_frontend_port The Port to be assigned to the APP GW frontend string 80 no
app_gw_sku_capacity Specifies instance count. Can be 1 to 10. string 2 no
app_gw_sku_name Possible values are: S_Small, S_Medium, S_Large, W_Medium and W_Large string S_Small no
app_gw_sku_tier Possible values are Standard and WAF string Standard no
app_gw_subnet_adr_prefix The address prefix to use for the application gateway subnet string 10.0.1.0/24 no
appgw_available_sku_names Specifies size of the application gateway map <map> no
appgw_available_sku_tiers Specifies the tier of the application gateway. Standard or WAF (Web Application Firewall) map <map> no
cookie_based_affinity Valid values are Enabled or Disabled string Disabled no
create_new_rg Whether or not to create a new resource group. Allowed values are true or false string must be set! yes
new_rg_name If set this will be the name of the new resource group string `` no
existing_rg Name of the existing resource group to put the module resources in string `` no
existing_vnet_id The ID of the existing Vnet string - yes
existing_vnet_name The name of the existing Vnet to associate the APP GW to string - yes
private_ip_allocation Priate IP address allocation. Either static or dynamic. Default is dynamic string dynamic no
location Default location for the azure resource string West Europe no
name_prefix Set by environmental variable string - no

Outputs

Name Description
application-gateway-RG The name of the resource group the Application Gateway is placed in
application-gateway-name Name of the Application Gateway
application-gateway-public-ip Public IP address assigned ot the Application Gateway

Usage examples of the Application Gateway module

Minimal config - Use existing resource group
module "application-gateway" {
  source             = "git::https://github.com/evry/tf-module-azure-application-gateway.git?ref=VERSION"
  name_prefix        = "${var.name_prefix}"
  create_new_rg      = "false"
  existing_rg        = "${azurerm_resource_group.test.name}"
  existing_vnet_name = "${azurerm_virtual_network.test.name}"
  existing_vnet_id   = "${azurerm_virtual_network.test.id}"
}
Minimal config - Create new resource group
module "application-gateway" {
  source        = "git::https://github.com/evry/tf-module-azure-application-gateway.git?ref=VERSION"
  name_prefix   = "${var.name_prefix}"
  create_new_rg = "true"
  new_rg_name   = "NAME-OF-NEW-RESOURCE-GROUP"
  existing_vnet_name = "${azurerm_virtual_network.test.name}"
  existing_vnet_id   = "${azurerm_virtual_network.test.id}"
}
Complete config - Use existing resource group
module "application-gateway" {
  source             = "git::https://github.com/evry/tf-module-azure-application-gateway.git?ref=VERSION"
  name_prefix        = "${var.name_prefix}"
  create_new_rg      = "false"
  existing_rg        = "${azurerm_resource_group.test.name}"
  existing_vnet_name = "${azurerm_virtual_network.test.name}"
  existing_vnet_id   = "${azurerm_virtual_network.test.id}"
  app_gw_sku_name          = "S_Medium"
  app_gw_sku_tier          = "Standard"
  app_gw_sku_capacity      = "2"
  app_gw_subnet_adr_prefix = "10.0.1.0/24"
  app_gw_frontend_port     = "443"
  app_gw_backend_port      = "80"
  app_gw_backend_protocol  = "http"
  cookie_based_affinity    = "Disabled"
  private_ip_allocation    = "dynamic"
}
Complete config - Create new resource group
module "application-gateway" {
  source             = "git::https://github.com/evry/tf-module-azure-application-gateway.git?ref=VERSION"
  name_prefix        = "${var.name_prefix}"
  create_new_rg      = "true"
  new_rg_name        = "NAME-OF-NEW-RESOURCE-GROUP"
  existing_rg        = "${azurerm_resource_group.test.name}"
  existing_vnet_name = "${azurerm_virtual_network.test.name}"
  existing_vnet_id   = "${azurerm_virtual_network.test.id}"
  app_gw_sku_name          = "S_Medium"
  app_gw_sku_tier          = "Standard"
  app_gw_sku_capacity      = "2"
  app_gw_subnet_adr_prefix = "10.0.1.0/24"
  app_gw_frontend_port     = "443"
  app_gw_backend_port      = "80"
  app_gw_backend_protocol  = "http"
  cookie_based_affinity    = "Disabled"
  private_ip_allocation    = "dynamic"
}

About

Azure terraform module for creating an Application Gateway

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages