mirror of
https://github.com/xcat2/xcat-core.git
synced 2026-10-07 18:16:34 +00:00
e3d8ebf699
The staging directory was keyed by package, target and uniqueext. Nothing deleted it, so every pair left a SOURCES tree under $HOME/rpmbuild, and an archive from an earlier run stayed beside the next run's sources. Each forked builder now stages into $HOME/rpmbuild/sources/SOURCES.<host>.<pid>. The pid is unique among live processes on one host, and the host name keeps two hosts apart when $HOME is on NFS. prepare_build_sources_dir creates the directory empty. The parent deletes it when it reaps the builder, whatever the exit, and abort_builds deletes it for each builder that exits after SIGTERM. At start, the run deletes the directories of this host whose pid is not alive. buildrpms_sources_per_package.t covers the name, the empty directory, the deletion after success and failure, and the sweep of a dead pid next to a live one and another host. Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>