summaryrefslogtreecommitdiffstats
path: root/roles/openshift_node/tasks
diff options
context:
space:
mode:
authorScott Dodson <sdodson@redhat.com>2017-07-18 08:19:27 -0400
committerScott Dodson <sdodson@redhat.com>2017-07-18 12:03:16 -0400
commit44fb8d5d9825bd5a708062dfe371763566d014e7 (patch)
treebef4237264d82cc960932d9d55b71b22620bacd1 /roles/openshift_node/tasks
parent4c8f1c1269aa8fa527816ad63a295f8863d8a6f8 (diff)
downloadopenshift-44fb8d5d9825bd5a708062dfe371763566d014e7.tar.gz
openshift-44fb8d5d9825bd5a708062dfe371763566d014e7.tar.bz2
openshift-44fb8d5d9825bd5a708062dfe371763566d014e7.tar.xz
openshift-44fb8d5d9825bd5a708062dfe371763566d014e7.zip
Dump some logs
Diffstat (limited to 'roles/openshift_node/tasks')
-rw-r--r--roles/openshift_node/tasks/main.yml11
1 files changed, 11 insertions, 0 deletions
diff --git a/roles/openshift_node/tasks/main.yml b/roles/openshift_node/tasks/main.yml
index 05721c882..879f6c207 100644
--- a/roles/openshift_node/tasks/main.yml
+++ b/roles/openshift_node/tasks/main.yml
@@ -216,6 +216,7 @@
state: started
when: openshift.common.is_containerized | bool
+
- name: Start and enable node
systemd:
name: "{{ openshift.common.service_type }}-node"
@@ -226,6 +227,16 @@
until: not node_start_result | failed
retries: 1
delay: 30
+ ignore_errors: true
+
+- name: Dump logs from node service if it failed
+ command: journalctl --no-pager -n 100 {{ openshift.common.service_type }}-node
+ when: node_start_result | failed
+
+- name: Abort if node failed to start
+ fail:
+ msg: Node failed to start please inspect the logs and try again
+ when: node_start_result | failed
- set_fact:
node_service_status_changed: "{{ node_start_result | changed }}"