I would like to run my own internal pypi server, for egg distribution within my organization.
我想运行我自己的内部pypi服务器,用于组织内的蛋分配。
I have found a few projects, such as:
我找到了一些项目,例如:
- http://pypi.python.org/pypi/EggBasket/
- http://pypi.python.org/pypi/EggBasket/
- http://plone.org/products/plonesoftwarecenter
- http://plone.org/products/plonesoftwarecenter
As I understand it, pypi.python.org uses software called Cheese Shop.
据我了解,pypi.python.org使用名为Cheese Shop的软件。
My questions:
我的问题:
- Why can't I use cheeseshop itself? (I can't find it, not sure it exists)
- 为什么我不能使用cheeseshop本身? (我找不到它,不确定它是否存在)
- How do other people solve this problem? (Currently we use blush svn to distribute eggs)
- 其他人如何解决这个问题? (目前我们使用腮红svn来分发鸡蛋)
*edit: This seems canonical http://wiki.python.org/moin/PyPiImplementations. Still, I'm interested in feedback.
*编辑:这似乎是规范的http://wiki.python.org/moin/PyPiImplementations。不过,我对反馈感兴趣。
10 个解决方案
#1
12
The source to Cheese Shop can be downloaded from https://bitbucket.org/pypa/pypi/src. There is also an example, from the page you linked to, of using Apache as a "dumb" Python package repository:
奶酪商店的来源可以从https://bitbucket.org/pypa/pypi/src下载。从您链接到的页面,还有一个使用Apache作为“哑”Python包存储库的示例:
# Mount pypi repositories into URI space
Alias /pypi /var/pypi
# /pypi/dev: Redirect for unknown packages (fallback to pypi)
RewriteCond /var/pypi/dev/$1 !-d
RewriteCond /var/pypi/dev/$1 !-f
RewriteRule ^/pypi/dev/([^/]+)/?$ http://pypi.python.org/pypi/$1/ [R,L]
RewriteCond /var/pypi/dev/$1/$2 !-f
RewriteRule ^/pypi/dev/([^/]+)/([^/]+)$ http://pypi.python.org/pypi/$1/$2 [R,L]
# /pypi/stable: Redirect for unknown packages (fallback to pypi)
RewriteCond /var/pypi/stable/$1 !-d
RewriteCond /var/pypi/stable/$1 !-f
RewriteRule ^/pypi/stable/([^/]+)/?$ http://pypi.python.org/pypi/$1/ [R,L]
RewriteCond /var/pypi/stable/$1/$2 !-f
RewriteRule ^/pypi/stable/([^/]+)/([^/]+)$ http://pypi.python.org/pypi/$1/$2 [R,L]
#3
4
Warehouse
Warehouse would be your best bet in 2017. From the project's README:
仓库将是您2017年最好的选择。从项目的自述文件:
Warehouse is a next generation Python Package Repository designed to replace the legacy code base that currently powers PyPI
Warehouse是下一代Python包存储库,旨在取代目前为PyPI提供支持的遗留代码库
...
...
You can run Warehouse locally using
docker
anddocker-compose
. See Getting started in the documentation for instructions on how to set it up.您可以使用docker和docker-compose在本地运行Warehouse。有关如何设置的说明,请参阅文档中的入门。
It is maintained by The Python Packaging Authority (PyPA) who work in cooperation with members of the Python core development team, and there is a live version running at https://pypi.org/ which mirrors everything in the legacy PyPI (https://pypi.python.org/).
它由Python包装管理局(PyPA)维护,他与Python核心开发团队的成员合作,并且有一个在https://pypi.org/上运行的实时版本,它反映了旧版PyPI中的所有内容(https: //pypi.python.org/)。
#4
3
There is a fork of djangopypi named djangopypi2 you can get it from https://github.com/popen2/djangopypi2/, I installed it and works for me, this option is what I had choose from a list of about 24 alternatives that I have found in a recently search, you can see the list here: http://uyeya.blogspot.com/2013/10/list-of-local-alternatives-of-pypi.html
有一个名为djangopypi的djangopypi的分支你可以从https://github.com/popen2/djangopypi2/获得它,我安装它并为我工作,这个选项是我从大约24个替代品的列表中选择我在最近的搜索中找到了,你可以在这里看到这个列表:http://uyeya.blogspot.com/2013/10/list-of-local-alternatives-of-pypi.html
#5
3
Updated: crate.io has shut down and the domain is now something else entirely.
更新:crate.io已关闭,域名现在完全不同了。
One project that hasn't been mentioned is https://crate.io/, which seems very active. It claims to be a "Next Generation Python Packaging Index", but they have their repositories split nicely into pieces that seem to welcome customization and remixing to your purposes.
一个尚未提及的项目是https://crate.io/,它似乎非常活跃。它声称是一个“下一代Python包装索引”,但他们的存储库很好地分成几块似乎欢迎定制和重新混合到你的目的。
#6
2
If you would like a lighter solution then deploying an entire pypi server, you could try using a server index generated by basketweaver.
如果您想要一个更轻的解决方案然后部署整个pypi服务器,您可以尝试使用basketweaver生成的服务器索引。
#7
1
devpi
We are using it in a corporate environment and are pretty satisfied. It supports replication, private indexes and index inheritance.
我们在企业环境中使用它并且非常满意。它支持复制,私有索引和索引继承。
#8
0
Another missing from this (oldish) list:
这个(旧的)列表中的另一个缺失:
djangopypi
Django based, which might be a slight overkill, but I love django and it makes it extremely simple to modify it to your need should it not be satisfying.
基于Django,这可能是一个轻微的矫枉过正,但我喜欢django,如果它不满意,它可以非常简单地根据你的需要进行修改。
#9
0
And crate source code is available, though documentation is, least that can be said, not-existent:
并且可以使用crate源代码,尽管文档可以说是最不可能的,但不存在:
Crate.Web
It's a Django Application providing a Python Package Index. Uses a couple other packages from https://github.com/crateio so you might be able to roll out your own version without django.
它是一个提供Python包索引的Django应用程序。使用https://github.com/crateio中的其他几个软件包,这样您就可以在没有django的情况下推出自己的版本。
I'm specifically thinking about a static one, I always thought there should be a very easy way to go explore directly some [pre-configured] repositories and shop cheese directly from my github/bitbucket public and private repos, with just a simple (gunicorn) process running.
我特别想到一个静态的,我一直认为应该有一个非常简单的方法直接探索一些[预先配置的]存储库和直接从我的github / bitbucket公共和私人回购店购买奶酪,只需一个简单的( gunicorn)进程运行。
#10
0
I ran into the same problem, and ClueReleaseManager solved the problem of hosting an internal PyPI server/custom Python repository for me.
我遇到了同样的问题,ClueReleaseManager解决了为我托管内部PyPI服务器/自定义Python存储库的问题。
That answers question two, and I guess you already have the answer to question one.
这回答了问题二,我想你已经有了问题一的答案。
#1
12
The source to Cheese Shop can be downloaded from https://bitbucket.org/pypa/pypi/src. There is also an example, from the page you linked to, of using Apache as a "dumb" Python package repository:
奶酪商店的来源可以从https://bitbucket.org/pypa/pypi/src下载。从您链接到的页面,还有一个使用Apache作为“哑”Python包存储库的示例:
# Mount pypi repositories into URI space
Alias /pypi /var/pypi
# /pypi/dev: Redirect for unknown packages (fallback to pypi)
RewriteCond /var/pypi/dev/$1 !-d
RewriteCond /var/pypi/dev/$1 !-f
RewriteRule ^/pypi/dev/([^/]+)/?$ http://pypi.python.org/pypi/$1/ [R,L]
RewriteCond /var/pypi/dev/$1/$2 !-f
RewriteRule ^/pypi/dev/([^/]+)/([^/]+)$ http://pypi.python.org/pypi/$1/$2 [R,L]
# /pypi/stable: Redirect for unknown packages (fallback to pypi)
RewriteCond /var/pypi/stable/$1 !-d
RewriteCond /var/pypi/stable/$1 !-f
RewriteRule ^/pypi/stable/([^/]+)/?$ http://pypi.python.org/pypi/$1/ [R,L]
RewriteCond /var/pypi/stable/$1/$2 !-f
RewriteRule ^/pypi/stable/([^/]+)/([^/]+)$ http://pypi.python.org/pypi/$1/$2 [R,L]
#2
#3
4
Warehouse
Warehouse would be your best bet in 2017. From the project's README:
仓库将是您2017年最好的选择。从项目的自述文件:
Warehouse is a next generation Python Package Repository designed to replace the legacy code base that currently powers PyPI
Warehouse是下一代Python包存储库,旨在取代目前为PyPI提供支持的遗留代码库
...
...
You can run Warehouse locally using
docker
anddocker-compose
. See Getting started in the documentation for instructions on how to set it up.您可以使用docker和docker-compose在本地运行Warehouse。有关如何设置的说明,请参阅文档中的入门。
It is maintained by The Python Packaging Authority (PyPA) who work in cooperation with members of the Python core development team, and there is a live version running at https://pypi.org/ which mirrors everything in the legacy PyPI (https://pypi.python.org/).
它由Python包装管理局(PyPA)维护,他与Python核心开发团队的成员合作,并且有一个在https://pypi.org/上运行的实时版本,它反映了旧版PyPI中的所有内容(https: //pypi.python.org/)。
#4
3
There is a fork of djangopypi named djangopypi2 you can get it from https://github.com/popen2/djangopypi2/, I installed it and works for me, this option is what I had choose from a list of about 24 alternatives that I have found in a recently search, you can see the list here: http://uyeya.blogspot.com/2013/10/list-of-local-alternatives-of-pypi.html
有一个名为djangopypi的djangopypi的分支你可以从https://github.com/popen2/djangopypi2/获得它,我安装它并为我工作,这个选项是我从大约24个替代品的列表中选择我在最近的搜索中找到了,你可以在这里看到这个列表:http://uyeya.blogspot.com/2013/10/list-of-local-alternatives-of-pypi.html
#5
3
Updated: crate.io has shut down and the domain is now something else entirely.
更新:crate.io已关闭,域名现在完全不同了。
One project that hasn't been mentioned is https://crate.io/, which seems very active. It claims to be a "Next Generation Python Packaging Index", but they have their repositories split nicely into pieces that seem to welcome customization and remixing to your purposes.
一个尚未提及的项目是https://crate.io/,它似乎非常活跃。它声称是一个“下一代Python包装索引”,但他们的存储库很好地分成几块似乎欢迎定制和重新混合到你的目的。
#6
2
If you would like a lighter solution then deploying an entire pypi server, you could try using a server index generated by basketweaver.
如果您想要一个更轻的解决方案然后部署整个pypi服务器,您可以尝试使用basketweaver生成的服务器索引。
#7
1
devpi
We are using it in a corporate environment and are pretty satisfied. It supports replication, private indexes and index inheritance.
我们在企业环境中使用它并且非常满意。它支持复制,私有索引和索引继承。
#8
0
Another missing from this (oldish) list:
这个(旧的)列表中的另一个缺失:
djangopypi
Django based, which might be a slight overkill, but I love django and it makes it extremely simple to modify it to your need should it not be satisfying.
基于Django,这可能是一个轻微的矫枉过正,但我喜欢django,如果它不满意,它可以非常简单地根据你的需要进行修改。
#9
0
And crate source code is available, though documentation is, least that can be said, not-existent:
并且可以使用crate源代码,尽管文档可以说是最不可能的,但不存在:
Crate.Web
It's a Django Application providing a Python Package Index. Uses a couple other packages from https://github.com/crateio so you might be able to roll out your own version without django.
它是一个提供Python包索引的Django应用程序。使用https://github.com/crateio中的其他几个软件包,这样您就可以在没有django的情况下推出自己的版本。
I'm specifically thinking about a static one, I always thought there should be a very easy way to go explore directly some [pre-configured] repositories and shop cheese directly from my github/bitbucket public and private repos, with just a simple (gunicorn) process running.
我特别想到一个静态的,我一直认为应该有一个非常简单的方法直接探索一些[预先配置的]存储库和直接从我的github / bitbucket公共和私人回购店购买奶酪,只需一个简单的( gunicorn)进程运行。
#10
0
I ran into the same problem, and ClueReleaseManager solved the problem of hosting an internal PyPI server/custom Python repository for me.
我遇到了同样的问题,ClueReleaseManager解决了为我托管内部PyPI服务器/自定义Python存储库的问题。
That answers question two, and I guess you already have the answer to question one.
这回答了问题二,我想你已经有了问题一的答案。