split Cloud NAT flag
This commit is contained in:
@@ -105,7 +105,7 @@ module "lod-vpc-firewall" {
|
||||
}
|
||||
|
||||
module "lod-nat" {
|
||||
count = var.network_config.network != null ? 0 : 1
|
||||
count = var.network_config.enable_cloud_nat ? 0 : 1
|
||||
source = "../../../modules/net-cloudnat"
|
||||
project_id = module.lod-prj.project_id
|
||||
region = var.location_config.region
|
||||
|
||||
@@ -132,7 +132,7 @@ module "orc-vpc-firewall" {
|
||||
}
|
||||
|
||||
module "orc-nat" {
|
||||
count = var.network_config.network != null ? 0 : 1
|
||||
count = var.network_config.enable_cloud_nat ? 0 : 1
|
||||
source = "../../../modules/net-cloudnat"
|
||||
project_id = module.orc-prj.project_id
|
||||
region = var.location_config.region
|
||||
|
||||
@@ -99,7 +99,7 @@ module "trf-vpc-firewall" {
|
||||
}
|
||||
|
||||
module "trf-nat" {
|
||||
count = var.network_config.network != null ? 0 : 1
|
||||
count = var.network_config.enable_cloud_nat ? 0 : 1
|
||||
source = "../../../modules/net-cloudnat"
|
||||
project_id = module.trf-prj.project_id
|
||||
region = var.location_config.region
|
||||
|
||||
@@ -58,7 +58,8 @@ variable "groups" {
|
||||
variable "network_config" {
|
||||
description = "Shared VPC to use. If not null networks will be created in projects."
|
||||
type = object({
|
||||
network = string
|
||||
enable_cloud_nat = bool
|
||||
network = string
|
||||
vpc_subnet_range = object({
|
||||
load = string
|
||||
transformation = string
|
||||
@@ -66,7 +67,8 @@ variable "network_config" {
|
||||
})
|
||||
})
|
||||
default = {
|
||||
network = null
|
||||
enable_cloud_nat = false
|
||||
network = null
|
||||
vpc_subnet_range = {
|
||||
load = "10.10.0.0/24"
|
||||
transformation = "10.10.0.0/24"
|
||||
|
||||
Reference in New Issue
Block a user