fix: retry docker push for large images on slow CI runners
Some checks failed
CI / check (push) Successful in 1m42s
CI / build-and-cache (push) Successful in 1m4s
CI / Build & Push OpenClaw Image (push) Successful in 31m38s
CI / Deploy OpenClaw to Cluster (push) Failing after 3s

This commit is contained in:
2026-04-20 10:27:15 -07:00
parent 618e6c7fd6
commit 6c18b6520c

View File

@@ -158,10 +158,15 @@ jobs:
- name: Push image
run: |
docker push registry.johnogle.info/openclaw:${{ steps.meta.outputs.tag }}
# Push latest tag separately — large images can timeout if pushed
# back-to-back. The versioned tag push above populates the registry
# layer cache, so this is mostly a manifest push.
# Push versioned tag with retry (large images can timeout on slow connections)
for i in 1 2 3; do
if docker push registry.johnogle.info/openclaw:${{ steps.meta.outputs.tag }}; then
break
fi
echo "Push attempt $i failed, retrying in 10s..."
sleep 10
done
# Push latest tag — mostly a manifest push since layers already exist
docker push registry.johnogle.info/openclaw:latest || \
echo "::warning::Failed to push :latest tag (versioned tag already pushed)"