diff --git a/common/deploy-steps-tasks.yaml b/common/deploy-steps-tasks.yaml index 7675b1a5dd..d045104e6c 100644 --- a/common/deploy-steps-tasks.yaml +++ b/common/deploy-steps-tasks.yaml @@ -25,7 +25,7 @@ no_log: true become: true - debug: var=(outputs.stderr|default('')).split('\n')|union(outputs.stdout_lines|default([])) - when: outputs is defined + when: outputs.rc is defined failed_when: outputs.rc not in [0, 2] ###################################### # Generate config via docker-puppet.py @@ -44,8 +44,8 @@ no_log: true become: true - debug: var=(outputs.stderr|default('')).split('\n')|union(outputs.stdout_lines|default([])) - when: outputs is defined - failed_when: outputs|failed + when: outputs.rc is defined + failed_when: outputs.rc != 0 ################################################## # Per step starting of the containers using paunch ################################################## @@ -70,8 +70,8 @@ no_log: true become: true - debug: var=(outputs.stderr|default('')).split('\n')|union(outputs.stdout_lines|default([])) - when: outputs is defined - failed_when: outputs|failed + when: outputs.rc is defined + failed_when: outputs.rc != 0 ######################################################## # Bootstrap tasks, only performed on bootstrap_server_id ######################################################## @@ -95,5 +95,5 @@ no_log: true become: true - debug: var=(outputs.stderr|default('')).split('\n')|union(outputs.stdout_lines|default([])) - when: outputs is defined - failed_when: outputs|failed + when: outputs.rc is defined + failed_when: outputs.rc != 0 diff --git a/extraconfig/services/kubernetes-master.yaml b/extraconfig/services/kubernetes-master.yaml index 189c084d71..16858cffb8 100644 --- a/extraconfig/services/kubernetes-master.yaml +++ b/extraconfig/services/kubernetes-master.yaml @@ -163,5 +163,5 @@ outputs: - name: print kubespray outputs debug: var: (outputs.stderr|default('')).split('\n')|union(outputs.stdout_lines|default([])) - failed_when: outputs|failed - when: outputs is defined + failed_when: outputs.rc != 0 + when: outputs.rc is defined