-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provide a knob to optionally skip creating the VPC related resources (#…
…330)
- Loading branch information
Showing
5 changed files
with
69 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// File containing the necessary data sources if local.enable_managed_vpc=false. | ||
// | ||
// The "local.enable_managed_vpc" variable will be set to false if all of | ||
// "var.external_vpc" fields are set. | ||
|
||
data "aws_vpc" "external" { | ||
count = local.enable_managed_vpc ? 0 : 1 | ||
id = var.external_vpc.id | ||
} | ||
|
||
data "aws_db_subnet_group" "external" { | ||
count = local.enable_managed_vpc ? 0 : 1 | ||
name = var.external_vpc.database_subnet_group_name | ||
} | ||
|
||
data "aws_subnet" "external_private" { | ||
count = local.enable_managed_vpc ? 0 : 1 | ||
id = var.external_vpc.private_subnet_id | ||
} | ||
|
||
data "aws_subnet" "external_public" { | ||
count = local.enable_managed_vpc ? 0 : 1 | ||
id = var.external_vpc.public_subnet_id | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters