Skip to content
This repository was archived by the owner on Nov 28, 2018. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions docs/source/installing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -101,12 +101,12 @@ authentication, so this shouldn't be used on production.

.. code-block:: bash

>>> sudo apt-get install apache2 libapache2-mod-wsgi
>>> sudo apt-get install python-setuptools python-dev libxml2-dev libxslt-dev
>>> sudo easy_install Flask-Pypi-Proxy
$ sudo apt-get install apache2 libapache2-mod-wsgi
$ sudo apt-get install python-setuptools python-dev libxml2-dev libxslt-dev
$ sudo easy_install Flask-Pypi-Proxy

>>> mkdir -p /mnt/eggs/
>>> sudo chown www-data:www-data -R /mnt/eggs/
$ mkdir -p /mnt/eggs/
$ sudo chown www-data:www-data -R /mnt/eggs/

Now, lets create the WSGI configuration file (in this example, I will
create it on /mnt/eggs/flask_pypi_proxy.wsgi). The content of that file
Expand Down Expand Up @@ -139,7 +139,7 @@ Restart Apache

.. code-block:: bash

>>> sudo service apache2 restart
$ sudo service apache2 restart


More advanced configuration
Expand All @@ -150,23 +150,23 @@ virtualenv, also using HTTP basic auth to create some security for the eggs.

.. code-block:: bash

>>> sudo apt-get install apache2 libapache2-mod-wsgi
>>> sudo apt-get install python-setuptools python-dev libxml2-dev libxslt-dev
$ sudo apt-get install apache2 libapache2-mod-wsgi
$ sudo apt-get install python-setuptools python-dev libxml2-dev libxslt-dev

Now, create the user where the virtualenv will be installed:

.. code-block:: bash

>>> sudo adduser pypi-proxy
$ sudo adduser pypi-proxy
Adding user `pypi-proxy' ...
Adding new group `pypi-proxy' (1001) ...
Adding new user `pypi-proxy' (1001) with group `pypi-proxy' ...
Creating home directory `/home/pypi-proxy' ...
Copying files from `/etc/skel' ...
Enter new UNIX password:
Retype new UNIX password:
>>> sudo easy_install virtualenv
>>> sudo su - pypi-proxy
$ sudo easy_install virtualenv
$ sudo su - pypi-proxy

The following steps will be executed as **pypi-proxy**:

Expand Down
10 changes: 5 additions & 5 deletions docs/source/using.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ To download a package from the proxy, there are two choices:

.. code-block:: bash

pip install -i http://mypypiproxy/simple/ Flask
easy_install -i http://mypypiproxy/simple/ Flask
$ pip install -i http://mypypiproxy/simple/ Flask
$ easy_install -i http://mypypiproxy/simple/ Flask

* Use the index url in a configuration file. For easy_install, it
should be on **~/.pydistutils.cfg** (on Linux), and the file should have
Expand Down Expand Up @@ -57,7 +57,7 @@ like:
I you are using the configuration with basic auth, then the configuration
file should look something like this:

.. code-block::
.. code-block:: ini

[distutils]
index-servers =
Expand All @@ -77,14 +77,14 @@ go to the **setup.py** of your project and run:

.. code-block:: bash

python setup.py sdist upload -r myserver
$ python setup.py sdist upload -r myserver

**IMPORTANT:** The command *register*, won't work if you are using basic auth.
For example, if you run

.. code-block:: bash

python setup.py register
$ python setup.py register

and if your server is configured using basic auth, then register will return
a 401 error. Simply upload the package without running register.