ci: keep build cache cleanup best-effort in the restore step [CI]
The restore step failed after restoring every dependency because the final cache cleanup (buildah unshare reporting memfd_create) was not guarded. Cleanup failures now only warn, and a test requires every cleanup call to be guarded.
This commit is contained in:
1 parent
c6d0c8637e
commit
13c16ad9c7
3 files changed
+16
-2
No files matched your search
@@ -149,8 +149,9 @@ PY
|
||||
done
|
||||
flock -u 9
|
||||
agent_lock_held=false
|
||||
# 清理只是尽力而为:依赖已经还原好了,清理失败(比如 buildah unshare 在这台主机上报 memfd_create 错误)不能让这一步失败
|
||||
if flock -n -x 9; then
|
||||
bash "$root/ci/cleanup-build-cache.sh"
|
||||
bash "$root/ci/cleanup-build-cache.sh" || echo 'warning: build cache cleanup failed' >&2
|
||||
flock -u 9
|
||||
fi
|
||||
fi
|
||||
Reference in new issue
Block a user