Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions plugins/modules/dcnm_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -5080,12 +5080,22 @@ def dcnm_intf_get_diff_deleted(self):

for have in self.have_all:
have_intf = have['ifName']
deletable = have['deletable']
if re.search(r"\d+\/\d+\/\d+", have_intf):
found, parent_type = self.dcnm_intf_get_parent(have_intf, have['mgmtIpAddress'])
# If have in want breakout and if match to E1/x/1 add to dict
# Else if match E1/x/2, etc. silently ignore, because we delete the breakout
# with the first sub if.
if re.search(r"\d+\/\d+\/1$", have_intf) and found:
if deletable is False:
self.changed_dict[0]["skipped"].append(
{
"Name": have_intf,
"Alias": have.get("alias"),
"Delete Reason": have["deleteReason"],
}
)
continue
payload = {'serialNumber': have['serialNo'],
'ifName': have['ifName']}
self.diff_delete_breakout.append(payload)
Expand Down