diff options
author | Jacopo <dedalusj@gmail.com> | 2015-01-17 00:18:10 +0100 |
---|---|---|
committer | Jacopo <dedalusj@gmail.com> | 2015-01-17 00:20:40 +0100 |
commit | 8dcffaf56fe8d5c708709d7463c793398e06cf3f (patch) | |
tree | e4ea61b1b8a30ed6885b96310635f3cf54ef4c4d /bin/ansible-playbook | |
parent | Removed early check for empty inventory (diff) | |
download | ansible-8dcffaf56fe8d5c708709d7463c793398e06cf3f.tar.xz ansible-8dcffaf56fe8d5c708709d7463c793398e06cf3f.zip |
Converted empty inventory error to warning
Diffstat (limited to 'bin/ansible-playbook')
-rwxr-xr-x | bin/ansible-playbook | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/bin/ansible-playbook b/bin/ansible-playbook index 485f2e1f89..03ca513c12 100755 --- a/bin/ansible-playbook +++ b/bin/ansible-playbook @@ -167,6 +167,8 @@ def main(args): inventory = ansible.inventory.Inventory(options.inventory, vault_password=vault_pass) inventory.subset(options.subset) + if len(inventory.list_hosts()) == 0: + utils.warning("provided hosts list is empty") # run all playbooks specified on the command line for playbook in args: |