generated from hashicorp/terraform-provider-scaffolding
-
Notifications
You must be signed in to change notification settings - Fork 175
Open
Description
I am trying to use netbox_vlans to return list of vlans based on a site's id. I have tried several combinations of formulating the block but have not been successful. See examples below;
data "netbox_vlans" "vlan_lookup" {
site = tostring(data.netbox_site.site_lookup.id)
}
╷
│ Error: Unsupported argument
│
│ on ../modules/netbox_interfaces/netbox_interfaces.tf line 81, in data "netbox_vlans" "vlan_lookup":
│ 81: site = tostring(data.netbox_site.site_lookup.id)
│
│ An argument named "site" is not expected here.
╵
data "netbox_vlans" "vlan_lookup" {
filter {
name = "site"
value = tostring(data.netbox_site.site_lookup.id)
}
}
╷
│ Error: 'site' is not a supported filter parameter
│
│ with module.device_interfaces["US-USA-TEST-SW001-1"].data.netbox_vlans.vlan_lookup,
│ on ../modules/netbox_interfaces/netbox_interfaces.tf line 93, in data "netbox_vlans" "vlan_lookup":
│ 93: data "netbox_vlans" "vlan_lookup" {
│
╵
Here is my provider setup;
terraform {
required_providers {
netbox = {
source = "e-breuninger/netbox"
version = ">= 3.9.2"
}
}
}
Can you provide some guidance as to how I can use this data source for my purposes?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels