From 79d91e024b2c0e6c32feb678bacf4303ddfa7fb2 Mon Sep 17 00:00:00 2001 From: Michael DeHaan Date: Tue, 28 Feb 2012 02:25:34 -0500 Subject: [PATCH] Updates to ansible-playbook helper program --- bin/ans-playbook | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/bin/ans-playbook b/bin/ans-playbook index db75f97bbad..87136ebc634 100755 --- a/bin/ans-playbook +++ b/bin/ans-playbook @@ -19,11 +19,16 @@ import sys import ansible.playbook -from ansible.scripts import base_ans_parser, error_print +import ansible.constants as C +from optparse import OptionParser def main(args): - parser = base_ans_parser(output_path=False) - parser.usage = "ans-playbook playbook.yml" + parser = OptionParser() + parser.usage = "ans-playbook playbook.yml ..." + parser.add_option('-f','--forks', dest='forks', default=C.DEFAULT_FORKS, type='int', + help='set the number of forks to start up') + parser.add_option("-L", "--library", dest="module_path", + help="path to module library", default=C.DEFAULT_MODULE_PATH) options, args = parser.parse_args(args) if len(args) == 0: @@ -34,7 +39,6 @@ def main(args): pb = ansible.playbook.PlayBook( playbook=playbook, module_path=options.module_path, - remote_user=options.remote_user, forks=options.forks, verbose=True )