[ceph-osd] update post apply job
The PS updates post apply job and moves execution of the command outside of if statement. The output of the command stored in a variable which will be checked in if statement. Added "-z" to correct comparison of the length of the string (variable). It was accidentally missed in the initial PS. Change-Id: I907f75d0a9e5ef27fba5306ddb86199e94b01b3b
This commit is contained in:
parent
dbd465c4c6
commit
787052a975
@ -41,7 +41,8 @@ function wait_for_pods() {
|
||||
select="select((.status) or (.phase==\"Succeeded\") | not)"
|
||||
query=".items | map( ${fields} | ${select}) | .[]"
|
||||
while true; do
|
||||
if [[ $(kubectl get pods --namespace="${1}" -o json | jq -c "${query}") ]]; then
|
||||
unhealthy_pods=$(kubectl get pods --namespace="${1}" -o json | jq -c "${query}")
|
||||
if [[ -z "${unhealthy_pods}" ]]; then
|
||||
break
|
||||
fi
|
||||
sleep 5
|
||||
|
Loading…
Reference in New Issue
Block a user