createrepo: external locking?
Oliver Hookins <[email protected]> Wed, 25 Aug 2010 14:56:20 +0200
| Newsgroups | gmane.linux.rpm.metadata |
|---|---|
| Message-ID | <[email protected]> |
Hi all, I've hit an interesting problem on some of our repositories we use for populating with our own applications. We have build servers generating RPMs automatically (sometimes on every scm commit) and these are then dumped into the yum repository directories and createrepo run on the directory to generate the metadata. At the moment, this means that every job in the build system that generates RPMs must have its own directory (and now there are quite a few) as multiple createrepo instances running against the same directory fails. We can't just run it from cron periodically as there are some triggered jobs which pull down the most recent metadata immediately afterwards to do some testing of the new packages. So, is there some way to get createrepo to lock a particular directory so that multiple processes can update the metadata at least sequentially? Or is this kind of thing best done with a wrapper around createrepo (or not at all)? Best Regards, Oliver