Каталог, '/home/deploy/.cache/pip/http' или его родительский каталог, не принадлежит текущему пользователю

enter image description here

Я пытаюсь загрузить ngxtop для контроля nginx на 16.04 LTS

deploy@server:~$ sudo pip install ngxtop
[sudo] password for deploy:
The directory '/home/deploy/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/deploy/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting ngxtop
  Downloading ngxtop-0.0.2-py2.py3-none-any.whl
Collecting pyparsing (from ngxtop)
  Downloading pyparsing-2.2.0-py2.py3-none-any.whl (56kB)
    100% |################################| 61kB 4.6MB/s
Collecting docopt (from ngxtop)
  Downloading docopt-0.6.2.tar.gz
    Complete output from command python setup.py egg_info:

    ----------------------------------------
Command "python setup.py egg_info" failed with error code -9 in /tmp/pip-build-qdsM8k/docopt/
Killed

Как я могу получить эту работу?

Править:

deploy@server:~$ sudo -H pip install ngxtop
[sudo] password for deploy:
Collecting ngxtop
  Downloading ngxtop-0.0.2-py2.py3-none-any.whl
Collecting pyparsing (from ngxtop)
  Downloading pyparsing-2.2.0-py2.py3-none-any.whl (56kB)
    100% |################################| 61kB 8.0MB/s
Collecting docopt (from ngxtop)
  Downloading docopt-0.6.2.tar.gz
Collecting tabulate (from ngxtop)
  Downloading tabulate-0.7.7-py2.py3-none-any.whl
Building wheels for collected packages: docopt
  Running setup.py bdist_wheel for docopt ... error
  Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-umz2So/docopt/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" bdist_wheel -d /tmp/tmpPmBPnfpip-wheel- --python-tag cp27:

  ----------------------------------------
  Failed building wheel for docopt
  Running setup.py clean for docopt
  Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-umz2So/docopt/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" clean --all:

  ----------------------------------------
  Failed cleaning build dir for docopt
Failed to build docopt
Installing collected packages: pyparsing, docopt, tabulate, ngxtop
  Running setup.py install for docopt ... error
    Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-umz2So/docopt/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-hUhxBo-record/install-record.txt --single-version-externally-managed --compile:

    ----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-umz2So/docopt/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-hUhxBo-record/install-record.txt --single-version-externally-managed --compile" failed with error code -9 in /tmp/pip-build-umz2So/docopt/
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.


deploy@server:~$ pip install --upgrade pip --user
Collecting pip
Killed
deploy@server:~$
0
задан 10 May 2017 в 11:50

0 ответов

Другие вопросы по тегам:

Похожие вопросы: