Makes client vpn cidr range configurable

This commit is contained in:
Rob Gil 2020-01-23 10:50:16 -05:00
parent 48482785ac
commit c31d68a18c
4 changed files with 15 additions and 2 deletions

View File

@ -110,7 +110,7 @@ resource "azurerm_virtual_network_gateway" "vnet_gateway" {
}
vpn_client_configuration {
address_space = ["172.16.1.0/24"]
address_space = var.vpn_client_cidr
vpn_client_protocols = ["OpenVPN"]
}
}

View File

@ -52,3 +52,9 @@ variable "service_endpoints" {
description = "A map of the service endpoints and its mapping to subnets"
}
variable "vpn_client_cidr" {
type = list
description = "The CIDR range used for clients on the VPN"
default = ["172.16.0.0/16"]
}

View File

@ -91,6 +91,12 @@ variable "admin_users" {
variable "admin_user_whitelist" {
type = map
default = {
"Rob Gil" = "66.220.238.246"
"Rob Gil" = "66.220.238.246"
"Dan Corrigan Work" = "108.16.207.173"
}
}
variable "vpn_client_cidr" {
type = list
default = ["172.16.255.0/24"]
}

View File

@ -10,5 +10,6 @@ module "vpc" {
name = var.name
dns_servers = var.dns_servers
service_endpoints = var.service_endpoints
vpn_client_cidr = var.vpn_client_cidr
}