[Fix] import job crashloop
- Relied on JSON field names being in a deterministic order. This is not guaranteed. Update import job to no longer assume this. Change-Id: I8d0a3abae94b99a94df61346b504517e2cb4a8ca
This commit is contained in:
parent
794a8b5ffb
commit
219c821b22
@ -47,7 +47,7 @@ function check_for_download {
|
||||
let JOB_TIMEOUT-=${RETRY_TIMER}
|
||||
sleep ${RETRY_TIMER}
|
||||
else
|
||||
synced_imgs=$(maas ${ADMIN_USERNAME} boot-resources read | grep -B 3 'Synced' | grep 'ubuntu' | wc -l)
|
||||
synced_imgs=$(maas ${ADMIN_USERNAME} boot-resources read | tr -d '\n' | grep -oE '{[^}]+}' | grep ubuntu | grep -c Synced)
|
||||
if [[ $synced_imgs -gt 0 ]]
|
||||
then
|
||||
echo 'Boot resources have completed importing'
|
||||
|
Loading…
x
Reference in New Issue
Block a user