Creating a local PyPI mirror

During the Blackforest Sprint a new package z3c.pypimirror has been created under the lead of Daniel Kraft. The major goal was to build up a distributed mirroring infrastructure. Why? PyPI is still a single point-of-failure and because there are a bunch of cases where you need an in-house mirror.

After  easy_install-ing  z3c.pypimrror you can use the pypimirror script for downlading all packages from PyPI (and as an option all external packages (experimental)). This requires roughly 4 GB of diskspace. After mirroring PyPI you can run a buildout against your local PyPI mirror. Right now I have full copy of PyPI available under By default zc.buildout asks PyPI always when looking up a package. You can avoid that by the following configuration in your buildout.cfg:

find-links =
allow-hosts = *

This configuration tells zc.buildout to also look for packages on my local server and to restrict any lookup to the hosts defined within the allow-hosts section - this works like a charm.

The local PyPI mirror also works nicely with easy_install:

easy_install -i <your package>
当前网页内容, 由 大妈 ZoomQuiet 使用工具: ScrapBook :: Firefox Extension 人工从互联网中收集并分享;
若有不妥, 欢迎评注提醒:


订阅 substack 体验古早写作:

点击注册~> 获得 100$ 体验券: DigitalOcean Referral Badge

关注公众号, 持续获得相关各种嗯哼:


关于 ~ DebugUself with DAMA ;-)
公安备案号: 44049002000656 ...::