"when" condition in handler is not honored

10 views
Skip to first unread message

Guy Matz

unread,
Jun 14, 2016, 10:42:01 AM6/14/16
to ansible...@googlegroups.com
Hi! 
I have a "when: condition that works fine in "regular" tasks, but not in a handler . . .  is that expected?  

So I'm using a notify, then at the end of the handler task I have a when condition.  The notification works, but it always triggers, ever when the condition is false.

Here's the handler:
- name: restart render
  supervisorctl:
    name: "render"
    state: restarted
  when: "'render' in group_names"

Any ideas?

Thanks a lot,
Guy

Reply all
Reply to author
Forward
0 new messages