-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
827c924
commit 6a48d4c
Showing
22 changed files
with
124 additions
and
32 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,30 @@ | ||
# the initial fabric construction happens in here | ||
module "fabric" { | ||
source = "../_modules/fabric" | ||
} | ||
|
||
# the null resource "disappears", forcing replacement whenever a | ||
# trigger value is changed. | ||
resource "null_resource" "force_redeploy" { | ||
depends_on = [module.fabric] | ||
triggers = { | ||
// replace this resource whenever staging blueprint is revised | ||
fabric_staging_revision = module.fabric.staging_revision | ||
} | ||
} | ||
|
||
#// deploy resource depends on the null resource which vanishes with each new | ||
#// blueprint revision. This way the blueprint is redeployed after every change | ||
#resource "apstra_blueprint_deployment" "dc_1" { | ||
# blueprint_id = module.fabric.blueprint_id | ||
# comment = "Deployment by Terraform {{.TerraformVersion}}, Apstra provider {{.ProviderVersion}}, User $USER." | ||
## depends_on = [module.fabric, module.vpn_routing, null_resource.force_redeploy] | ||
#} | ||
|
||
#module "vpn_routing" { | ||
# source = "./_vpn_routing" | ||
# blueprint_id = module.fabric.blueprint_id | ||
# routing_zone_id = module.fabric.routing_zone_id | ||
# vpn_edge_router_ip = local.vpn_edge_router_ip | ||
# vpn_routing_policies = local.vpn_routing_policies | ||
#} |
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,2 @@ | ||
output blueprint_id { value = module.fabric.blueprint_id } | ||
output routing_zone_id { value = module.fabric.routing_zone_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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,8 @@ | ||
data "terraform_remote_state" "fabric" { | ||
backend = "s3" | ||
config = { | ||
bucket = "inform-demo" | ||
key = "fabric/terraform.tfstate" | ||
region = "us-east-1" | ||
} | ||
} |
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,7 @@ | ||
module "vpn_routing" { | ||
source = "../_modules/vpn_routing" | ||
blueprint_id = data.terraform_remote_state.fabric.outputs.blueprint_id | ||
routing_zone_id = data.terraform_remote_state.fabric.outputs.routing_zone_id | ||
vpn_edge_router_ip = local.vpn_edge_router_ip | ||
vpn_routing_policies = local.vpn_routing_policies | ||
} |
File renamed without changes.
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,19 @@ | ||
terraform { | ||
required_providers { | ||
apstra = { | ||
source = "Juniper/apstra" | ||
version = "0.27.2" | ||
} | ||
} | ||
backend "s3" { | ||
bucket = "inform-demo" | ||
key = "vpn/terraform.tfstate" | ||
region = "us-east-1" | ||
} | ||
} | ||
|
||
provider "apstra" { | ||
tls_validation_disabled = true | ||
blueprint_mutex_enabled = false | ||
api_timeout = 0 | ||
} |