I've had some success using the following expression (to check wether
ansible is in a list of installed packages or if it is from pip/manual
install):
"{{ 'ansible' in pkgs.results|default([])|map(attribute='name') }}"
Regards,
Daniel
On 05/26/2016 03:03 PM, Paul Tötterman wrote:
> Hi,
>
> Related to the recent mount deprecation thread:
>
> - command: mount /srv
> when: "'/srv' not in [x['mount'] for x in ansible_mounts]"
>
> But it seems that when statement is too complex. Any ideas how to
> express that in a valid way?
>
> Ideas about how to use mount: state=mounted without touching fstab also
> welcome
>
> Cheers,
> Paul
>
> --
> 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 [email protected]
> <mailto:[email protected]>.
> To post to this group, send email to [email protected]
> <mailto:[email protected]>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/872c67cf-9a08-47ba-b0a4-3b479f6cd213%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/872c67cf-9a08-47ba-b0a4-3b479f6cd213%40googlegroups.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.
--
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/ansible-project/840f48a2-21dd-7b17-f93c-9b0e493b5d42%40danieln.de.
For more options, visit https://groups.google.com/d/optout.