Skip to content

Commit

Permalink
update acl interface. (ansible#57905)
Browse files Browse the repository at this point in the history
* update acl interface.

* update ce_interface

* update

* add a changelog fragment.

* update
  • Loading branch information
yuandongx authored and ansibot committed Jun 28, 2019
1 parent b93411a commit da72644
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
bugfixes:
- ce_acl_interface - Strict regularity can't find anything.
6 changes: 3 additions & 3 deletions lib/ansible/modules/network/cloudengine/ce_acl_interface.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ def check_args(self):
msg='Error: The len of acl_name is out of [1 - 32].')

if self.interface:
cmd = "display current-configuration | ignore-case section include ^interface %s$" % self.interface
cmd = "display current-configuration | ignore-case section include interface %s" % self.interface
rc, out, err = exec_command(self.module, cmd)
if rc != 0:
self.module.fail_json(msg=err)
Expand Down Expand Up @@ -199,7 +199,7 @@ def get_proposed(self):
def get_existing(self):
""" Get existing config """

cmd = "display current-configuration | ignore-case section include ^interface %s$ | include traffic-filter" % self.interface
cmd = "display current-configuration | ignore-case section include interface %s | include traffic-filter" % self.interface
rc, out, err = exec_command(self.module, cmd)
if rc != 0:
self.module.fail_json(msg=err)
Expand All @@ -217,7 +217,7 @@ def get_existing(self):
def get_end_state(self):
""" Get config end state """

cmd = "display current-configuration | ignore-case section include ^interface %s$ | include traffic-filter" % self.interface
cmd = "display current-configuration | ignore-case section include interface %s | include traffic-filter" % self.interface
rc, out, err = exec_command(self.module, cmd)
if rc != 0:
self.module.fail_json(msg=err)
Expand Down

0 comments on commit da72644

Please sign in to comment.