如何创建本地pypi镜像?
How to create a local pypi mirror?
我想按照web教程创建本地pypi镜像
set local pypi mirror
这是我的方式。
wget https://bootstrap.pypa.io/get-pip.py
sudo python2.7 get-pip.py
sudo pip2.7 install pep381client
mkdir mirror
pep381run /tmp/mirror
此处出现错误信息:
Traceback (most recent call last):
File "/usr/local/bin/pep381run", line 23, in <module>
state = pep381client.Synchronization.initialize(targetdir)
File "/usr/local/lib/python2.7/dist-packages/pep381client/__init__.py", line 96, in initialize
status.projects_to_do = set(xmlrpc().list_packages())
File "/usr/lib/python2.7/xmlrpclib.py", line 1243, in __call__
return self.__send(self.__name, args)
File "/usr/lib/python2.7/xmlrpclib.py", line 1602, in __request
verbose=self.__verbose
File "/usr/lib/python2.7/xmlrpclib.py", line 1283, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib/python2.7/xmlrpclib.py", line 1331, in single_request
response.msg,
xmlrpclib.ProtocolError: <ProtocolError for pypi.python.org/pypi: 403 Must access using HTTPS instead of HTTP>
如何创建本地pypi镜像?
pep381client
似乎已经过时(最后更新于 2011 年)。您需要更新鲜的东西,例如 devpi
或 pypi-server
.
我想按照web教程创建本地pypi镜像
set local pypi mirror
这是我的方式。
wget https://bootstrap.pypa.io/get-pip.py
sudo python2.7 get-pip.py
sudo pip2.7 install pep381client
mkdir mirror
pep381run /tmp/mirror
此处出现错误信息:
Traceback (most recent call last):
File "/usr/local/bin/pep381run", line 23, in <module>
state = pep381client.Synchronization.initialize(targetdir)
File "/usr/local/lib/python2.7/dist-packages/pep381client/__init__.py", line 96, in initialize
status.projects_to_do = set(xmlrpc().list_packages())
File "/usr/lib/python2.7/xmlrpclib.py", line 1243, in __call__
return self.__send(self.__name, args)
File "/usr/lib/python2.7/xmlrpclib.py", line 1602, in __request
verbose=self.__verbose
File "/usr/lib/python2.7/xmlrpclib.py", line 1283, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib/python2.7/xmlrpclib.py", line 1331, in single_request
response.msg,
xmlrpclib.ProtocolError: <ProtocolError for pypi.python.org/pypi: 403 Must access using HTTPS instead of HTTP>
如何创建本地pypi镜像?
pep381client
似乎已经过时(最后更新于 2011 年)。您需要更新鲜的东西,例如 devpi
或 pypi-server
.