From f9f30cc8ec7434922551ba7f3d3ca6545a854b81 Mon Sep 17 00:00:00 2001 From: Tobias Richter Date: Mon, 3 Aug 2020 17:10:36 +0200 Subject: [PATCH] Fix issue in older jenkins versions that to not set a cookie --- tasks/gather_jenkins_facts.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tasks/gather_jenkins_facts.yml b/tasks/gather_jenkins_facts.yml index 3e064c7..6e717aa 100644 --- a/tasks/gather_jenkins_facts.yml +++ b/tasks/gather_jenkins_facts.yml @@ -40,7 +40,7 @@ - name: "gather_jenkins_facts : set jenkins csrf crumb." set_fact: jenkins_facts_csrf_crumb: "{{ _jenkins_facts_csrf_crumb_result.json.crumb }}" - jenkins_facts_cookie: "{{ _jenkins_facts_csrf_crumb_result.set_cookie }}" + jenkins_facts_cookie: "{{ _jenkins_facts_csrf_crumb_result.set_cookie | default(None) }}" when: jenkins_facts_csrf_enabled | bool