Allow multiple patterns to specified, just like Func did.
This commit is contained in:
parent
70ec508ee0
commit
cb90df2377
1 changed files with 4 additions and 2 deletions
|
@ -83,8 +83,10 @@ class Runner(object):
|
||||||
return False
|
return False
|
||||||
if not pattern:
|
if not pattern:
|
||||||
pattern = self.pattern
|
pattern = self.pattern
|
||||||
if fnmatch.fnmatch(host_name, pattern):
|
subpatterns = pattern.split(";")
|
||||||
return True
|
for subpattern in subpatterns:
|
||||||
|
if fnmatch.fnmatch(host_name, subpattern):
|
||||||
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
def _connect(self, host):
|
def _connect(self, host):
|
||||||
|
|
Loading…
Reference in a new issue