Hi. Has include_tasks been deprecated? I have a playbook that used include_tasks fine up until recently.
ansible-playbook --version reports 2.7.0
Unfortunately I can’t be sure of what the previous version was, if it was indeed different.
Either way, include_tasks no longer works for me. I get this error:
ERROR! Invalid options for include_tasks: item
The error appears to have been in ‘/vagrant/workspace/pcf-automation-infrastructure/ansible/bosh/prep.yml’: line 53, column 7, but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:
include_tasks: …/roles/common/tasks/download.yml item={{item}}
^ here
We could be wrong, but this one looks like it might be an issue with
missing quotes. Always quote template expression brackets when they
start a value. For instance:
You are setting a variable named item to the variable named item. That is unnecessary, and does nothing for you. Simply omitting item={{item}} will do the same thing.