over 1 year ago

## How to setup pypi server

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:

Config pypyserver settings:

Enter the following info in to .pypirc:

Setup the packages dir, this is the place where you store the packages:

Run!

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:

• pbr
• pip
• setuptools
• six
• stevedore
• virtualenv
• virtualenv-clone
• virtualenvwrapper
• wheel

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 ~/packages folder.

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).

Put the following lines into pip.conf