diff options
author | jctanner <tanner.jc@gmail.com> | 2013-12-02 19:04:18 +0100 |
---|---|---|
committer | jctanner <tanner.jc@gmail.com> | 2013-12-02 19:04:18 +0100 |
commit | 6d80c50fafd371fb8a24d1a0a19e9db996b60199 (patch) | |
tree | 819b6df29b72257783f9912af7ef4b2b51c278e6 /bin | |
parent | Fixes #4796 handle unicodedecode errors from dmidecode output (diff) | |
parent | Exit 0 with no matched hosts (diff) | |
download | ansible-6d80c50fafd371fb8a24d1a0a19e9db996b60199.tar.xz ansible-6d80c50fafd371fb8a24d1a0a19e9db996b60199.zip |
Merge pull request #4817 from j2sol/zero-exit
Exit 0 with no matched hosts
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ansible | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/ansible b/bin/ansible index f8c72234c8..3d4cb07ad9 100755 --- a/bin/ansible +++ b/bin/ansible @@ -81,8 +81,8 @@ class Cli(object): inventory_manager.subset(options.subset) hosts = inventory_manager.list_hosts(pattern) if len(hosts) == 0: - callbacks.display("No hosts matched", stderr=True) - sys.exit(1) + callbacks.display("No hosts matched") + sys.exit(0) if options.listhosts: for host in hosts: |