summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authoryanzhangi <51999930+yanzhangi@users.noreply.github.com>2019-09-18 22:27:51 +0800
committerToshio Kuratomi <a.badger@gmail.com>2019-09-18 07:27:51 -0700
commit2549af3f237c1530a730d5f9444c8d5c2f4b6d1c (patch)
tree20b49adca2249cc9295a137bb307b393a668e9fc /lib
parenta0fb290a87e13b407006b914fa10801783e747d9 (diff)
downloadansible-2549af3f237c1530a730d5f9444c8d5c2f4b6d1c.tar.gz
[Backport/2.9/61995]Update ce_vxlan_arp to fix bugs (#62505)
* 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 12512f731984ecb5bacb750e555dc4ef697c2b12) * update ce_vxlan_arp to fix bugs
Diffstat (limited to 'lib')
-rw-r--r--lib/ansible/modules/network/cloudengine/ce_vxlan_arp.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/ansible/modules/network/cloudengine/ce_vxlan_arp.py b/lib/ansible/modules/network/cloudengine/ce_vxlan_arp.py
index 1cd6c91c9a..72d1d98505 100644
--- a/lib/ansible/modules/network/cloudengine/ce_vxlan_arp.py
+++ b/lib/ansible/modules/network/cloudengine/ce_vxlan_arp.py
@@ -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)