I would like to mirror the following Yum/RPM repositories at http://yum.puppetlabs.com/ :
The Puppet repository contains every Puppet product ever released and is quite large at about 8GB. I only need to mirror the newest versions of the files.
I have tried to mirror the repository using
reposync --config=puppetlabs.repo.el6 --repoid=puppetlabs-products --repoid=puppetlabs-deps --newest-only --download_path=el/6 --quiet --downloadcomps
and this downloads the newest packages like I need. However, reposync doesn't automatically create the regular directory structure (
SRPMS, etc.) and doesn't mirror
repodata.xml. As a result, my yum clients get errors like this:
[root@web1 ~]# yum --quiet install puppet http://mirrors.example.org/pub/puppet/el/6/puppetlabs-deps/x86_64/repodata/repomd.xml: [Errno 14] PYCURL ERROR 22 - "The requested URL returned error: 404 Not Found" Trying other mirror. Error: Cannot retrieve repository metadata (repomd.xml) for repository: puppetlabs-deps. Please verify its path and try again [root@web1 ~]#
Is there a way to programmatically mirror only the new files from a Yum repo and follow the standard repository directory structure?