Closed lokeuei closed 4 years ago
To build an ICNR tunnel we expect to have a resource available, an example for the configuration can be:
resource "skytap_environment" "env1" {
template_id = ""
name = "env1"
description = "This is an environment created by the skytap terraform"
}
resource "skytap_environment" "env2" {
template_id = ""
name = "env2"
description = "This is an environment created by the skytap terraform"
}
resource "skytap_network" "net1" {
environment_id = "${skytap_environment.env1.id}"
name = "net1"
domain = "domain.com"
subnet = "10.0.100.0/24"
gateway = "10.0.100.254"
tunnelable = true
}
resource "skytap_network" "net2" {
environment_id = "${skytap_environment.env2.id}"
name = "net2"
domain = "domain.com"
subnet = "10.0.200.0/24"
gateway = "10.0.200.254"
tunnelable = true
}
resource "skytap_icnr_tunnel" "tunnel" {
source = "${skytap_network.net1.id}"
target = "${skytap_network.net2.id}"
}
Where the tunnel join both networks from two different environments.
Customer expects the ability to create ICNR tunnels at per the API but in Terraform: Equivalent of the API call: https://cloud.skytap.com/v2/tunnels.json
Configuration documented: https://help.skytap.com/Networking_Between_Environments.html