Another fix for --limit in adhoc
This commit is contained in:
parent
babf47decb
commit
c860775b5d
1 changed files with 1 additions and 1 deletions
|
@ -119,7 +119,7 @@ class AdHocCLI(CLI):
|
||||||
|
|
||||||
if self.options.subset:
|
if self.options.subset:
|
||||||
inventory.subset(self.options.subset)
|
inventory.subset(self.options.subset)
|
||||||
if len(inventory.list_hosts()) == 0 and not no_hosts:
|
if len(inventory.list_hosts(pattern)) == 0 and not no_hosts:
|
||||||
# Invalid limit
|
# Invalid limit
|
||||||
raise AnsibleError("Specified --limit does not match any hosts")
|
raise AnsibleError("Specified --limit does not match any hosts")
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue