diff --git a/bin/ansible-pull b/bin/ansible-pull index 83f281463f..8c624f4ef2 100755 --- a/bin/ansible-pull +++ b/bin/ansible-pull @@ -150,7 +150,10 @@ def main(args): now = datetime.datetime.now() print >>sys.stderr, now.strftime("Starting ansible-pull at %F %T") - inv_opts = 'localhost,' + if not options.inventory: + inv_opts = 'localhost,' + else: + inv_opts = options.inventory limit_opts = 'localhost:%s:127.0.0.1' % hostname repo_opts = "name=%s dest=%s" % (options.url, options.dest)