diff options
author | Scott Dodson <sdodson@redhat.com> | 2017-07-18 15:10:37 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-07-18 15:10:37 -0400 |
commit | 8e2be54c6f2f55368f33667a68a5693dc75b1027 (patch) | |
tree | 0f63035787dce728f9fa994a2dad78cff5bb9f0c /roles/openshift_node_upgrade/handlers | |
parent | 742203529902ba278c213e326f81f667304b9625 (diff) | |
parent | 5a94fe5b074d01a3b16db8a05c47c31e484e5ebe (diff) | |
download | openshift-8e2be54c6f2f55368f33667a68a5693dc75b1027.tar.gz openshift-8e2be54c6f2f55368f33667a68a5693dc75b1027.tar.bz2 openshift-8e2be54c6f2f55368f33667a68a5693dc75b1027.tar.xz openshift-8e2be54c6f2f55368f33667a68a5693dc75b1027.zip |
Merge pull request #4698 from sdodson/service-retries
Service retries
Diffstat (limited to 'roles/openshift_node_upgrade/handlers')
-rw-r--r-- | roles/openshift_node_upgrade/handlers/main.yml | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/roles/openshift_node_upgrade/handlers/main.yml b/roles/openshift_node_upgrade/handlers/main.yml index cb51416d4..110dfe5ce 100644 --- a/roles/openshift_node_upgrade/handlers/main.yml +++ b/roles/openshift_node_upgrade/handlers/main.yml @@ -1,7 +1,13 @@ --- - name: restart openvswitch - systemd: name=openvswitch state=restarted + systemd: + name: openvswitch + state: restarted when: (not skip_node_svc_handlers | default(False) | bool) and not (ovs_service_status_changed | default(false) | bool) and openshift.common.use_openshift_sdn | bool + register: l_openshift_node_upgrade_stop_openvswitch_result + until: not l_openshift_node_upgrade_stop_openvswitch_result | failed + retries: 3 + delay: 30 notify: - restart openvswitch pause @@ -10,5 +16,13 @@ when: (not skip_node_svc_handlers | default(False) | bool) and openshift.common.is_containerized | bool - name: restart node - systemd: name={{ openshift.common.service_type }}-node state=restarted - when: (not skip_node_svc_handlers | default(False) | bool) and not (node_service_status_changed | default(false) | bool) + systemd: + name: "{{ openshift.common.service_type }}-node" + state: restarted + register: l_openshift_node_upgrade_restart_node_result + until: not l_openshift_node_upgrade_restart_node_result | failed + retries: 3 + delay: 30 + when: + - (not skip_node_svc_handlers | default(False) | bool) + - not (node_service_status_changed | default(false) | bool) |