I had the pleasure of setting up my own pypi server last week because the server I had to work with is behind a corporate firewall.
To setup your own pypi server, here is what to do:
- Download pypiserver, then:
Config pypyserver settings:
Enter the following info in to
Setup the packages dir, this is the place where you store the packages:
You might want to keep the server running even after you logout of terminal:
You need to stuff your packages folder so that there will be something for
pip install, here are essential packages you need to at least get a virtual environment running:
To download these packages, just go to
https://pypi.python.org/pypi/ and search for the package name, then download the tar.gz version of that package. Once downloaded, move the zip file to the
To verify that the server is up and running， simply go to
localhost:8080/simple/, you should see a list of package names (or empty if you haven't copied any packages into the packages folder yet).
Config your client to download python packages from your server:
Put the following lines into
Done! Try using pip install and it will download a package instantly from your ~/packages folder and install it :)