From e4bfd2e829ff83c34642806d59a4c987539234dc Mon Sep 17 00:00:00 2001 From: Sorin Sbarnea Date: Wed, 9 Jan 2019 15:06:28 +0000 Subject: [PATCH] Implement workaround for failure to load ansible.cfg While the correct fix for this is to stop using fetch-zuul-cloner job, this is not possible right now as is imported by zuul base job. infra-root said that they it will take more time for the zuul base to be fixed due to risk involved on very-old jobs, so we need to implement a local fix for tripleo. Change-Id: I14abcb3273e68e267d6bcc7b2a060486bbd77351 Partial-Bug: 1807703 --- roles/common/tasks/main.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/roles/common/tasks/main.yml b/roles/common/tasks/main.yml index 5dbe502f0..5af15e88f 100644 --- a/roles/common/tasks/main.yml +++ b/roles/common/tasks/main.yml @@ -1,5 +1,15 @@ # In ansible 2.7 should be enough to add the option public: true to the calling include_role -# for this role. THis is the best workaround +# for this role. This is the best workaround - name: Include the vars to be available for the playbook include_vars: dir: vars + +# Workaround for https://launchpad.net/bugs/1807703 safe to remove only once +# fetch-zuul-cloner is no longer part of zuul base job. +- name: apply o-w workaround on src to avoid failure to load ansible.cfg + file: + path: "{{ ansible_user_dir }}/src" + state: directory + recurse: yes + mode: o-w + become: yes