diff options
author | Jan Chaloupka <jchaloup@redhat.com> | 2017-05-19 14:18:01 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-19 14:18:01 +0200 |
commit | 129dd9ccfb329ea296ad526acd4adf02c4004864 (patch) | |
tree | 5491a4c5a298ce13ec1207ce02bb95cc8e4c64b9 | |
parent | 80a71ef857cf6268d5f27c4c68bcd59f2c110af5 (diff) | |
parent | 644228de3fd18f47399290535cb3aca5e2bfa009 (diff) | |
download | openshift-129dd9ccfb329ea296ad526acd4adf02c4004864.tar.gz openshift-129dd9ccfb329ea296ad526acd4adf02c4004864.tar.bz2 openshift-129dd9ccfb329ea296ad526acd4adf02c4004864.tar.xz openshift-129dd9ccfb329ea296ad526acd4adf02c4004864.zip |
Merge pull request #4094 from ashcrow/status-doesnt-exist
Ensure good return code for specific until loops
-rw-r--r-- | playbooks/common/openshift-node/restart.yml | 2 | ||||
-rw-r--r-- | roles/openshift_node_upgrade/tasks/main.yml | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/playbooks/common/openshift-node/restart.yml b/playbooks/common/openshift-node/restart.yml index 441b100e9..01cf948e0 100644 --- a/playbooks/common/openshift-node/restart.yml +++ b/playbooks/common/openshift-node/restart.yml @@ -51,7 +51,7 @@ register: node_output delegate_to: "{{ groups.oo_first_master.0 }}" when: inventory_hostname in groups.oo_nodes_to_config - until: node_output.results.results[0].status.conditions | selectattr('type', 'match', '^Ready$') | map(attribute='status') | join | bool == True + until: node_output.results.returncode == 0 and node_output.results.results[0].status.conditions | selectattr('type', 'match', '^Ready$') | map(attribute='status') | join | bool == True # Give the node two minutes to come back online. retries: 24 delay: 5 diff --git a/roles/openshift_node_upgrade/tasks/main.yml b/roles/openshift_node_upgrade/tasks/main.yml index a41a97e01..7231bdb9d 100644 --- a/roles/openshift_node_upgrade/tasks/main.yml +++ b/roles/openshift_node_upgrade/tasks/main.yml @@ -143,7 +143,7 @@ name: "{{ openshift.common.hostname | lower }}" register: node_output delegate_to: "{{ groups.oo_first_master.0 }}" - until: node_output.results.results[0].status.conditions | selectattr('type', 'match', '^Ready$') | map(attribute='status') | join | bool == True + until: node_output.results.returncode == 0 and node_output.results.results[0].status.conditions | selectattr('type', 'match', '^Ready$') | map(attribute='status') | join | bool == True # Give the node two minutes to come back online. retries: 24 delay: 5 |