Removes the vnet gateway since we're no longer going to use Azure VPN services
This commit is contained in:
@@ -72,45 +72,3 @@ resource "azurerm_route" "route" {
|
||||
address_prefix = "0.0.0.0/0"
|
||||
next_hop_type = each.value
|
||||
}
|
||||
|
||||
# Required for the gateway
|
||||
resource "azurerm_subnet" "gateway" {
|
||||
name = "GatewaySubnet"
|
||||
resource_group_name = azurerm_resource_group.vpc.name
|
||||
virtual_network_name = azurerm_virtual_network.vpc.name
|
||||
address_prefix = var.gateway_subnet
|
||||
}
|
||||
|
||||
|
||||
resource "azurerm_public_ip" "vpn_ip" {
|
||||
name = "${var.name}-${var.environment}-vpn-ip"
|
||||
location = azurerm_resource_group.vpc.location
|
||||
resource_group_name = azurerm_resource_group.vpc.name
|
||||
|
||||
allocation_method = "Dynamic"
|
||||
}
|
||||
|
||||
resource "azurerm_virtual_network_gateway" "vnet_gateway" {
|
||||
name = "${var.name}-${var.environment}-gateway"
|
||||
location = azurerm_resource_group.vpc.location
|
||||
resource_group_name = azurerm_resource_group.vpc.name
|
||||
|
||||
type = "Vpn"
|
||||
vpn_type = "RouteBased"
|
||||
|
||||
active_active = false
|
||||
enable_bgp = false
|
||||
sku = "Standard"
|
||||
|
||||
ip_configuration {
|
||||
name = "vnetGatewayConfig"
|
||||
public_ip_address_id = azurerm_public_ip.vpn_ip.id
|
||||
private_ip_address_allocation = "Dynamic"
|
||||
subnet_id = azurerm_subnet.gateway.id
|
||||
}
|
||||
|
||||
vpn_client_configuration {
|
||||
address_space = var.vpn_client_cidr
|
||||
vpn_client_protocols = ["OpenVPN"]
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user