[Backport/2.8/61995]update ce_vxlan_arp to fix bugs (#62504)

* Update ce_vxlan_arp to fix bugs (#61995)

* Update ce_vxlan_arp to fix bugs

* Update ce_vxlan_arp to fix bugs

(cherry picked from commit 12512f7319)

* update ce_vxlan_arp to fix bugs
pull/62552/head
yanzhangi 6 years ago committed by Toshio Kuratomi
parent 9f2e500c5b
commit 4052c790cd

@ -0,0 +1,2 @@
bugfixes:
- ce_vxlan_arp - update to fix some bugs - Modifying regular expressions. (https://github.com/ansible/ansible/pull/61995)

@ -286,12 +286,12 @@ class VxlanArp(object):
"""get current configuration"""
flags = list()
exp = "| ignore-case section include evn bgp|host collect protocol bgp"
exp = r"| ignore-case section include evn bgp|host collect protocol bgp"
if self.vbdif_name:
exp += "|^interface %s$" % self.vbdif_name
exp += r"|^#\s+interface %s\s+" % self.vbdif_name.lower().capitalize().replace(" ", "")
if self.bridge_domain_id:
exp += "|^bridge-domain %s$" % self.bridge_domain_id
exp += r"|^#\s+bridge-domain %s\s+" % self.bridge_domain_id
flags.append(exp)
cfg_str = self.get_config(flags)

Loading…
Cancel
Save