pause – Pause playbook execution¶
Synopsis¶
- Pauses playbook execution for a set amount of time, or until a prompt is acknowledged. All parameters are optional. The default behavior is to pause with a prompt.
- To pause/wait/sleep per host, use the wait_for module.
- You can use
ctrl+c
if you wish to advance a pause earlier than it is set to expire or if you need to abort a playbook run entirely. To continue early pressctrl+c
and thenc
. To abort a playbook pressctrl+c
and thena
. - The pause module integrates into async/parallelized playbooks without any special considerations (see Rolling Updates). When using pauses with the
serial
playbook parameter (as in rolling updates) you are only prompted once for the current group of hosts. - This module is also supported for Windows targets.
Parameters¶
Notes¶
Note
- Starting in 2.2, if you specify 0 or negative for minutes or seconds, it will wait for 1 second, previously it would wait indefinitely.
- This module is also supported for Windows targets.
- User input is not captured or echoed, regardless of echo setting, when minutes or seconds is specified.
Examples¶
# Pause for 5 minutes to build app cache.
- pause:
minutes: 5
# Pause until you can verify updates to an application were successful.
- pause:
# A helpful reminder of what to look out for post-update.
- pause:
prompt: "Make sure org.foo.FooOverload exception is not present"
# Pause to get some sensitive input.
- pause:
prompt: "Enter a secret"
echo: no
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Status¶
- This module is guaranteed to have backward compatible interface changes going forward. [stableinterface]
- This module is maintained by the Ansible Core Team. [core]
Red Hat Support¶
More information about Red Hat’s support of this module is available from this Red Hat Knowledge Base article.
Authors¶
- Tim Bielawa (@tbielawa)
Hint
If you notice any issues in this documentation, you can edit this document to improve it.