summaryrefslogtreecommitdiff
path: root/playbooks
diff options
context:
space:
mode:
authorTobias Henkel <tobias.henkel@bmw.de>2018-09-15 15:26:01 +0200
committerTobias Henkel <tobias.henkel@bmw.de>2018-09-29 13:13:00 +0200
commit30cb2b1484ef2d11947ced38a8bde58a5cbf7f0a (patch)
tree401ad694c685ba2c92802f90a80ebf6aaefb9d03 /playbooks
parentf7f8ea617a64c3e949286fe977efbe93863d5f06 (diff)
downloadzuul-30cb2b1484ef2d11947ced38a8bde58a5cbf7f0a.tar.gz
Fix unreachable nodes detection
According to the docs ansible is expected to return 3 if there were unreachable nodes. Zuul reacts on this and retries the job. However ansible really returns 4 in this case [1] which actually is the code for a parse error (which doesn't make sense to retry). To work around that add a simple callback plugin that gets notified if there are unreachable nodes and write the information about which nodes failed to a special file beneath the job-output.txt. The executor can detect this and react properly then. Further we have the information about which nodes failed in this file which gets uploaded to the log server too if it exists. [1] https://github.com/ansible/ansible/issues/19720 Change-Id: I6d609835dba18b50dcbe883d01c6229ce4e38d91
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/zuul-stream/functional.yaml2
1 files changed, 2 insertions, 0 deletions
diff --git a/playbooks/zuul-stream/functional.yaml b/playbooks/zuul-stream/functional.yaml
index 779a10278..a9535cd9f 100644
--- a/playbooks/zuul-stream/functional.yaml
+++ b/playbooks/zuul-stream/functional.yaml
@@ -5,6 +5,7 @@
command: ansible-playbook src/git.openstack.org/openstack-infra/zuul/playbooks/zuul-stream/fixtures/test-stream.yaml
environment:
ZUUL_JOB_LOG_CONFIG: "{{ ansible_user_dir}}/logging.json"
+ ZUUL_JOBDIR: "{{ ansible_user_dir}}"
ARA_LOG_CONFIG: "{{ ansible_user_dir}}/logging.json"
- name: Run ansible playbook that should fail
@@ -13,6 +14,7 @@
failed_when: "failed_results.rc != 2"
environment:
ZUUL_JOB_LOG_CONFIG: "{{ ansible_user_dir}}/logging.json"
+ ZUUL_JOBDIR: "{{ ansible_user_dir}}"
ARA_LOG_CONFIG: "{{ ansible_user_dir}}/logging.json"
- name: Validate output - setupvar