[minigraph] Add tags for egress mirror tables (#4526)

Signed-off-by: Danny Allen <daall@microsoft.com>
This commit is contained in:
Danny Allen 2020-05-06 15:43:29 -07:00 committed by Abhishek Dosi
parent 11ce7617d2
commit 4079d39697
3 changed files with 8 additions and 2 deletions

View File

@ -393,8 +393,8 @@ def parse_dpg(dpg, hname):
# Give a warning if trying to attach ACL to a LAG member interface, correct way is to attach ACL to the LAG interface
if port_alias_map[member] in intfs_inpc:
print >> sys.stderr, "Warning: ACL " + aclname + " is attached to a LAG member interface " + port_alias_map[member] + ", instead of LAG interface"
elif member.lower().startswith('erspan'):
if member.lower().startswith('erspanv6'):
elif member.lower().startswith('erspan') or member.lower().startswith('egress_erspan'):
if member.lower().startswith('erspanv6') or member.lower().startswith('egress_erspanv6'):
is_mirror_v6 = True
else:
is_mirror = True

View File

@ -303,6 +303,11 @@
<InAcl>everflowV6</InAcl>
<Type>Everflow</Type>
</AclInterface>
<AclInterface>
<AttachTo>EGRESS_ERSPAN</AttachTo>
<OutAcl>everflow_egress</OutAcl>
<Type>Everflow</Type>
</AclInterface>
<AclInterface>
<AttachTo>PortChannel01;PortChannel02;PortChannel03;PortChannel04</AttachTo>
<InAcl>DataAclIngress</InAcl>

View File

@ -111,6 +111,7 @@ class TestCfgGen(TestCase):
"Warning: ignore interface 'fortyGigE0/2' in DEVICE_NEIGHBOR as it is not in the port_config.ini\n"
"{'NTP_ACL': {'services': ['NTP'], 'type': 'CTRLPLANE', 'policy_desc': 'NTP_ACL', 'stage': 'ingress'}, "
"'EVERFLOW': {'stage': 'ingress', 'type': 'MIRROR', 'ports': ['PortChannel01', 'PortChannel02', 'PortChannel03', 'PortChannel04', 'Ethernet4'], 'policy_desc': 'EVERFLOW'}, "
"'EVERFLOW_EGRESS': {'stage': 'egress', 'type': 'MIRROR', 'ports': ['PortChannel01', 'PortChannel02', 'PortChannel03', 'PortChannel04', 'Ethernet4'], 'policy_desc': 'EVERFLOW_EGRESS'}, "
"'ROUTER_PROTECT': {'services': ['SSH', 'SNMP'], 'type': 'CTRLPLANE', 'policy_desc': 'ROUTER_PROTECT', 'stage': 'ingress'}, "
"'DATAACLINGRESS': {'stage': 'ingress', 'type': 'L3', 'ports': ['PortChannel01', 'PortChannel02', 'PortChannel03', 'PortChannel04'], 'policy_desc': 'DATAACLINGRESS'}, "
"'SNMP_ACL': {'services': ['SNMP'], 'type': 'CTRLPLANE', 'policy_desc': 'SNMP_ACL', 'stage': 'ingress'}, "