Skip to content

Commit

Permalink
fix: data equinix_network_device_type return more than 1 result (#46)
Browse files Browse the repository at this point in the history
Signed-off-by: Oscar Cobles <[email protected]>
  • Loading branch information
ocobles authored Aug 29, 2024
1 parent 45cea92 commit 40690ce
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions modules/c8000v/main.tf
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
data "equinix_network_device_type" "this" {
category = "ROUTER"
vendor = "Cisco"
locals {
equinix_network_device_type_code = "C8000V"
}

data "equinix_network_device_platform" "this" {
device_type = data.equinix_network_device_type.this.code
device_type = local.equinix_network_device_type_code
flavor = var.platform
}

data "equinix_network_device_software" "this" {
device_type = data.equinix_network_device_type.this.code
device_type = local.equinix_network_device_type_code
packages = [var.software_package]
stable = true
most_recent = true
Expand All @@ -21,7 +20,7 @@ resource "equinix_network_device" "non_cluster" {
name = var.name
project_id = var.project_id
hostname = var.hostname
type_code = data.equinix_network_device_type.this.code
type_code = local.equinix_network_device_type_code
package_code = var.software_package
version = data.equinix_network_device_software.this.version
core_count = data.equinix_network_device_platform.this.core_count
Expand Down

0 comments on commit 40690ce

Please sign in to comment.