diff options
author | Seth Vidal <skvidal@fedoraproject.org> | 2013-04-09 01:53:40 -0400 |
---|---|---|
committer | Seth Vidal <skvidal@fedoraproject.org> | 2013-04-09 01:53:40 -0400 |
commit | 690738ea32a317ff6de4927d7168ba5053c49a87 (patch) | |
tree | 40218b27b2495fd9a429b0cbb49979e670f94ee4 /bin | |
parent | 586ee923a611231eeea4b1f353a44ab15efb5c53 (diff) | |
download | ansible-690738ea32a317ff6de4927d7168ba5053c49a87.tar.gz |
implement --start-at-task option to hop to a specific task before starting running them
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ansible-playbook | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bin/ansible-playbook b/bin/ansible-playbook index 917d00e6ff..751bbee1fc 100755 --- a/bin/ansible-playbook +++ b/bin/ansible-playbook @@ -74,6 +74,8 @@ def main(args): help="do list all tasks that would be executed") parser.add_option('--step', dest='step', action='store_true', help="one-step-at-a-time: confirm each task before running") + parser.add_option('--start-at-task', dest='start_at', + help="start the playbook with a task matching this name") options, args = parser.parse_args(args) @@ -115,6 +117,8 @@ def main(args): playbook_cb = callbacks.PlaybookCallbacks(verbose=utils.VERBOSITY) if options.step: playbook_cb.step = options.step + if options.start_at: + playbook_cb.start_at = options.start_at runner_cb = callbacks.PlaybookRunnerCallbacks(stats, verbose=utils.VERBOSITY) pb = ansible.playbook.PlayBook( |