Ah! Fantastic. Thank you. I put in max_fail_percentage, and the thing I 
wanted to happen happened.

I do wonder about how to more elegantly handle one of the nodes failing, 
with a handler. Like something simple to start: "prompt: pause here, go fix 
that node if you can. If you can't, ctrl-c now."  Perhaps I should add 
"ignore_failures: true" and experiment?

It's strange .. I do have another task that runs per webapp node that runs 
a local check script -- it's a ruby program that will exit non-zero upon 
error condition. When any node has failed that check, the ansible run comes 
to a screeching halt. That play contains no max_fail_percentage and no 
ignore_failure: true.

We use ansible 1.8.2.

I'll move forward with your advice. And, FWIW ... this bombs out the entire 
run when any node fails:

---
- hosts: '{{ myhosts }}'
  gather_facts: False
  serial: '{{ serial }}'
  tasks:

  - name: App port check
    shell: app-port-check --config /opt/app/conf/config.yaml
    when: port_check
    register: oslout
  - debug: var=oslout
    when: debug and port_check

  - name: Message private hipchat room
    hipchat: token={{ hipchat_token }} room={{ priv_hipchat_room }} from={{ 
hipchat_user }} msg="App sidedoor check successful for {{ 
inventory_hostname }}"
    when: verbose|bool and msg_private|bool and port_check|bool
    ignore_errors: true



-- 
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/6b6688a1-5a22-4bfe-8552-d2487c556237%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to