John,
What if you try this in your play?
- name: Configure firewall
include: firewall.yml
when: pg_host != "localhost"
Jay
On Tuesday, December 30, 2014 12:20:00 PM UTC-6, John Oliver wrote:
>
> ansible 1.7.2
>
> My play:
>
> - name: Configure firewall
> include: firewall.yml
> when: "{{pg_host}} != localhost"
>
> gets me:
>
> TASK: [postgres | Check if postgres is already allowed via IPv4]
> **************
> fatal: [jedis-test] => error while evaluating conditional: localhost !=
> localhost
>
>
> This looks like a case where ansible could maybe be a little more verbose?
> The line that's failing is the first play in firewall.yml I'm guessing
> I'm just not clear on how to run another playbook if my variable is not
> equal to localhost.
>
--
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/690611aa-800d-42f9-8b43-179d3e70e6cd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.