Hi! 2015-10-30 22:00 GMT+01:00 Johannes Schauer <jo...@debian.org>: > What would the benefit be to have a --apt-get-update-failed-commands hook? > Which hook would one like to run when "apt-get update" failed?
I have a local repository of built packages linked to my sbuild instances. Everytime a build is successful, the repository indexes are updated. In case of multiple builds, it could happen newer concurrent builds start to update apt cache just in the middle of a apt-ftparchive run, resulting in a "hash sum mismatch" error. I would like to implement a simple locking mechanism using plain files (it's definitely not the best approach, I welcome better ideas ;). I acquire the lock in the chroot-setup and I should manage the removal of the lock if something goes wrong in whatever stage. With the current status, if sbuild fails in apt-get-update the lock is never deleted because no commands are triggered. -- Cheers, Luca