On Wed, 6 Nov 2019 05:56:46 -0500
Mauricio Tavares <raubvo...@gmail.com> wrote:

> - include: string.yml
>   when: string_test|default(False)
> [...]
> TASK [test : Create strings] **************************************
> *
> skipping: [testmail]
> [...]
> which are listing tasks inside string.yml. Yes, it is skipping said
> tasks but I thought it would not try to peek at that task file to
> begin with. Is that expected behaviour or I did something wrong?


Use *include_tasks* instead of *include*.

Quoting:"Prior to Ansible 2.4, only include was available and it behaved
differently depending on context". See "Including and Importing"
https://docs.ansible.com/ansible/latest/user_guide/playbooks_reuse_includes.html#including-and-importing

Cheers,

        -vlado

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/20191106125627.0d4943ec%40gmail.com.

Attachment: pgpM3TI4LFupR.pgp
Description: OpenPGP digital signature

Reply via email to