Keywords
Every play, block and task keyword ansible-core 2.19 knows, and what Volant does with each one.
Ce contenu n’est pas encore disponible dans votre langue.
Volant loads a playbook against the whole ansible-core 2.19 grammar, so it parses here as it parses under Ansible. What this release does not support yet is named before the run starts, never accepted and then ignored. Each keyword has a status for each place it can be written.
- runsVolant honors it, or names the one value it does not support yet.
- not acceptedCannot be written there. Ansible rejects it too, when it reads the playbook.
A keyword inside a file that only a dynamic include_tasks or include_role names is checked when a host reaches that statement: if it is not supported yet, the statement fails for that host, a rescue around it can catch the failure, and nothing in the file runs. See Includes and imports.
A keyword that takes a boolean or a number may be written as a template: become, no_log, run_once, any_errors_fatal, ignore_unreachable, delegate_facts, timeout, async and poll. It is rendered for each host when its task runs, once the task’s when has held, and a value the keyword cannot take fails the task with the reference’s sentence. gather_facts, force_handlers, strategy and order of a play are rendered when the play starts, with the play’s variables and the extra vars. A literal that is not a boolean is refused when the playbook loads. A timeout that is negative or not a number fails its task when it runs, as in Ansible, even when written as a literal.
This page is generated from the tables the loader and the pre-flight read, so it always describes the release it ships with. A status says what Volant does with the keyword, not that every value works: the known gaps list the values that fail.
All keywords
Section titled “All keywords”| Keyword | Play | Block | Task |
|---|---|---|---|
action | not accepted | not accepted | runs |
always | not accepted | runs | not accepted |
any_errors_fatal | runs | runs | runs |
args | not accepted | not accepted | runs |
async | not accepted | not accepted | runs |
become | runs | runs | runs |
become_exe | runs | runs | runs |
become_flags | runs | runs | runs |
become_method | runs | runs | runs |
become_user | runs | runs | runs |
block | not accepted | runs | not accepted |
changed_when | not accepted | not accepted | runs |
check_mode | runs | runs | runs |
collections | runs | runs | runs |
connection | runs | runs | runs |
debugger | runs | runs | runs |
delay | not accepted | not accepted | runs |
delegate_facts | not accepted | runs | runs |
delegate_to | not accepted | runs | runs |
diff | runs | runs | runs |
environment | runs | runs | runs |
fact_path | runs | not accepted | not accepted |
failed_when | not accepted | not accepted | runs |
force_handlers | runs | not accepted | not accepted |
gather_facts | runs | not accepted | not accepted |
gather_subset | runs | not accepted | not accepted |
gather_timeout | runs | not accepted | not accepted |
handlers | runs | not accepted | not accepted |
hosts | runs | not accepted | not accepted |
ignore_errors | runs | runs | runs |
ignore_unreachable | runs | runs | runs |
local_action | not accepted | not accepted | runs |
loop | not accepted | not accepted | runs |
loop_control | not accepted | not accepted | runs |
max_fail_percentage | runs | not accepted | not accepted |
module_defaults | runs | runs | runs |
name | runs | runs | runs |
no_log | runs | runs | runs |
notify | not accepted | runs | runs |
order | runs | not accepted | not accepted |
poll | not accepted | not accepted | runs |
port | runs | runs | runs |
post_tasks | runs | not accepted | not accepted |
pre_tasks | runs | not accepted | not accepted |
register | not accepted | not accepted | runs |
remote_user | runs | runs | runs |
rescue | not accepted | runs | not accepted |
retries | not accepted | not accepted | runs |
roles | runs | not accepted | not accepted |
run_once | runs | runs | runs |
serial | runs | not accepted | not accepted |
strategy | runs | not accepted | not accepted |
tags | runs | runs | runs |
tasks | runs | not accepted | not accepted |
throttle | runs | runs | runs |
timeout | runs | runs | runs |
until | not accepted | not accepted | runs |
vars | runs | runs | runs |
vars_files | runs | not accepted | not accepted |
vars_prompt | runs | not accepted | not accepted |
when | not accepted | runs | runs |
with_config | not accepted | not accepted | runs |
with_csvfile | not accepted | not accepted | runs |
with_dict | not accepted | not accepted | runs |
with_env | not accepted | not accepted | runs |
with_file | not accepted | not accepted | runs |
with_fileglob | not accepted | not accepted | runs |
with_first_found | not accepted | not accepted | runs |
with_indexed_items | not accepted | not accepted | runs |
with_ini | not accepted | not accepted | runs |
with_inventory_hostnames | not accepted | not accepted | runs |
with_items | not accepted | not accepted | runs |
with_lines | not accepted | not accepted | runs |
with_list | not accepted | not accepted | runs |
with_nested | not accepted | not accepted | runs |
with_password | not accepted | not accepted | runs |
with_pipe | not accepted | not accepted | runs |
with_random_choice | not accepted | not accepted | runs |
with_sequence | not accepted | not accepted | runs |
with_subelements | not accepted | not accepted | runs |
with_template | not accepted | not accepted | runs |
with_together | not accepted | not accepted | runs |
with_unvault | not accepted | not accepted | runs |
with_url | not accepted | not accepted | runs |
with_varnames | not accepted | not accepted | runs |
with_vars | not accepted | not accepted | runs |
Limits of what runs
Section titled “Limits of what runs”| Keyword | Limit |
|---|---|
any_errors_fatal |
A template counts as true whatever it renders to, as ansible-core 2.19 reads it, and the task then fails on a value that is not a boolean |
debugger |
p and a line that is not a command evaluate a subset of Python: names, literals, indexing, attributes, assignments and the calls the prompt needs. task_vars edited at the prompt reach a redo through u only |
gather_facts |
A template is rendered once, when the play starts, with the play’s variables. The play still counts as one that may gather facts, so it needs ansible-core to be there |
no_log |
A template is rendered for each host when its task runs. In a loop, one item that hides hides every item, where ansible-core hides each item by its own value |
run_once |
A template is read for each host of the batch, and the first host it is true for runs the task. A template that is true for some hosts and false for others ends the run, where ansible-core also runs the hosts in front of the first. Under free and host_pinned a template is ignored without the warning a literal gets |
Handlers
Section titled “Handlers”A handler accepts every task keyword above, plus one of its own.
| Keyword | Status |
|---|---|
listen |
runs |
Under loop_control
Section titled “Under loop_control”A sub-key ansible-core does not know is rejected when the playbook loads.
| Sub-key | Status |
|---|---|
break_when |
runs |
extended |
runs |
extended_allitems |
runs |
index_var |
runs |
label |
runs |
loop_var |
runs |
pause |
runs |