Tools to mirror Linux distro repositories. https://r00t2.io/
Go to file
brent s 3676acfc00
fixing dict comprehension
/usr/local/lib/repomirror/repomirror/sync.py:361: UserWarning: The sync process for arch is locked with file /var/run/repomirror/arch.lck and PID 2981337.
  warnings.warn(warnmsg)
Traceback (most recent call last):
  File "/usr/local/bin/reposync", line 56, in <module>
    main()
  File "/usr/local/bin/reposync", line 51, in main
    r.sync()
  File "/usr/local/lib/repomirror/repomirror/sync.py", line 435, in sync
    distro.sync()
  File "/usr/local/lib/repomirror/repomirror/sync.py", line 363, in sync
    proc_info = {k.lstrip('_'):v for k, v in vars(proc) if k not in ('_lock', '_proc')}
  File "/usr/local/lib/repomirror/repomirror/sync.py", line 363, in <dictcomp>
    proc_info = {k.lstrip('_'):v for k, v in vars(proc) if k not in ('_lock', '_proc')}
ValueError: too many values to unpack (expected 2)
2020-07-24 22:50:13 -04:00
repomirror fixing dict comprehension 2020-07-24 22:50:13 -04:00
.gitignore v1.0.1 2020-06-18 00:29:12 -04:00
example.config.xml Automated commit (/opt/dev/infra/gitclass.py) 2020-07-23 23:15:17 -04:00
LICENSE aaand should add a LICENSE. thanks, amayer! 2020-06-17 20:15:13 -04:00
README Automated commit (/opt/dev/infra/gitclass.py) 2020-07-23 23:15:17 -04:00
reposync adding in some delay checking calculation and parsing of xs:duration types. 2020-07-23 12:05:36 -04:00
reposync.py adding in some delay checking calculation and parsing of xs:duration types. 2020-07-23 12:05:36 -04:00
requirements.txt adding requirements.txt ... thanks, amayer. 2020-06-17 20:43:28 -04:00
setup.py v1.0.1 2020-06-18 00:29:12 -04:00

This project will let you mirror a Linux distribution's repository/repositories (or BSD, etc.).


Features:

* Logging
* RSync or FTP supported (RSync mirrors require rsync to be installed and in the $PATH environment variable) (HTTP/HTTPS cannot and will not be supported as there's no real way to do it reliably and efficiently.)
* Locking - prevent a specific distribution from syncing if it is currently being synced but allow other distributions to sync
* Customizable rsync arguments
* Changing of directory/file ownership per-distribution
* Mount-checking per-distribution - a distribution will be skipped if its designated mountpoint is not mounted
* Synchronization checks - timestamp files can be read and written and are used to determine if a sync should take place or not


Configuration/Deployment:

See example.config.xml for details on a configuration file, as it's extensively commented and won't be covered in this README.

You can also run reposync -h (or reposync --help) to see all supported options.

You may take special interest in repomirror/utils/find_fastest_upstream/ scripts as they're pre-written to find the fastest (in theory) upstream you can use. Currently only Arch Linux and CentOS have scripts written, but I'll gladly try to add other distros if you open a feature request (see below). You can run -h/--help to see the supported options (there aren't many).


Bugs/Feature Requests:

Please use my tracker at https://bugs.square-r00t.net/index.php?project=14 or, if you prefer to not create an account, simply email me at bts(at)square-r00t[dot]net.


Sources:

This project can be found at/cloned from:

* https://git.square-r00t.net/RepoMirror
* git://git.square-r00t.net/repomirror.git

And has a mirrored repository on GitHub (Issues/Wiki/etc. disabled) at:

* https://github.com/johnnybubonic/repomirror

It can also be found on PyPi at:

* https://pypi.org/project/repomirror/