aboutsummaryrefslogtreecommitdiffhomepage
path: root/tasks
diff options
context:
space:
mode:
Diffstat (limited to 'tasks')
-rw-r--r--tasks/rundeck.yml12
1 files changed, 12 insertions, 0 deletions
diff --git a/tasks/rundeck.yml b/tasks/rundeck.yml
index 007b86e..1250d24 100644
--- a/tasks/rundeck.yml
+++ b/tasks/rundeck.yml
@@ -19,6 +19,18 @@
19 register: rundeck_create_jobs 19 register: rundeck_create_jobs
20 with_items: "{{ rundeck_jobs_files.files}}" 20 with_items: "{{ rundeck_jobs_files.files}}"
21 21
22- name: Check if a job failed
23 fail:
24 msg: "Job defined in {{ file }} has failed with message: {{ message }}"
25 with_items: "{{ rundeck_create_jobs.results }}"
26 loop_control:
27 label: "{{ item.item.path }}"
28 vars:
29 file: "{{ item.item.path }}"
30 message: "{{ item.json.failed }}"
31 when: item.json.failed|length > 0
32 ignore_errors: "{{ rundeck_ignore_creation_error }}"
33
22- name: Get all jobs 34- name: Get all jobs
23 uri: 35 uri:
24 url: "{{rundeck_api_url }}/{{rundeck_api_version}}/project/{{ rundeck_project }}/jobs?groupPathExact={{ rundeck_jobs_group | default(rundeck_empty_group_path) }}" 36 url: "{{rundeck_api_url }}/{{rundeck_api_version}}/project/{{ rundeck_project }}/jobs?groupPathExact={{ rundeck_jobs_group | default(rundeck_empty_group_path) }}"