From 42826a79206fd476b7bc4fe0a61b33242d43e55c Mon Sep 17 00:00:00 2001 From: Andrew Schoen Date: Tue, 11 Oct 2016 10:39:52 -0500 Subject: [PATCH] ansible: ignore failures change /etc/hosts cloud templates Not all our nodes have those templates so ignore failures to modify those non-existant templates. Signed-off-by: Andrew Schoen --- ansible/examples/slave.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ansible/examples/slave.yml b/ansible/examples/slave.yml index 61a752e2..e75adba9 100644 --- a/ansible/examples/slave.yml +++ b/ansible/examples/slave.yml @@ -198,17 +198,21 @@ # set to true on the image we use in OVH and some jobs will reboot # these nodes causing the /etc/hosts file to be replace with these # templates making jobs fail because the hostname is not resolvable + # not all our images have this setting though, so ignore failures on + # those nodes - name: update the etc cloud templates for debian /etc/hosts sudo: true lineinfile: dest: /etc/cloud/templates/hosts.debian.tmpl line: '127.0.1.1 ceph-builders' + failed_when: false - name: update the etc cloud templates for debian /etc/hosts sudo: true lineinfile: dest: /etc/cloud/templates/hosts.redhat.tmpl line: '127.0.1.1 ceph-builders' + failed_when: false - name: install six, latest one sudo: true -- 2.47.3