-
Notifications
You must be signed in to change notification settings - Fork 0
/
ethernet_network.tf
26 lines (26 loc) · 1 KB
/
ethernet_network.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#__________________________________________________________________
#
# Intersight Ethernet Network Policy
# GUI Location: Policies > Create Policy > Ethernet Network
#__________________________________________________________________
resource "intersight_vnic_eth_network_policy" "map" {
for_each = local.ethernet_network
description = coalesce(each.value.description, "${each.value.name} Ethernet Network Policy.")
name = each.value.name
organization { moid = var.orgs[each.value.org] }
vlan_settings {
allowed_vlans = "" # CSCvx98712. This is no longer valid for the policy
default_vlan = each.value.default_vlan
mode = each.value.vlan_mode
object_type = "vnic.VlanSettings"
qinq_enabled = each.value.qinq_vlan != 0 ? true : false
qinq_vlan = each.value.qinq_vlan == 0 ? 2 : each.value.qinq_vlan
}
dynamic "tags" {
for_each = { for v in each.value.tags : v.key => v }
content {
key = tags.value.key
value = tags.value.value
}
}
}