[PYTHON] Wget fails during install with pyenv

Install python 2.6.6 with pyenv

# pyenv install 2.6.6

...Abbreviation

error: failed to install setuptools via ez_setup.py

BUILD FAILED

Inspect or clean up the working tree at /tmp/python-build.20141031114520.16491
Results logged to /tmp/python-build.20141031114520.16491.log

Last 10 log lines:
    downloader_factory=options.downloader_factory,
  File "/tmp/python-build.20141031114520.16491/ez_setup.py", line 287, in download_setuptools
    downloader(url, saveto)
  File "/tmp/python-build.20141031114520.16491/ez_setup.py", line 224, in download_file_wget
    _clean_check(cmd, target)
  File "/tmp/python-build.20141031114520.16491/ez_setup.py", line 169, in _clean_check
    subprocess.check_call(cmd)
  File "/root/.pyenv/versions/2.6.6/lib/python2.6/subprocess.py", line 488, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['wget', 'https://pypi.python.org/packages/source/s/setuptools/setuptools-7.0.zip', '--quiet', '--output-document', '/tmp/python-build.20141031114520.16491/Python-2.6.6/setuptools-7.0.zip']' returned non-zero exit status 1

When I looked up various things, it seems that the connection by SSL was not established at the time of wget, so I disabled the SSL check and it worked for the time being.

echo "check_certificate = off" >> /etc/wgetrc

Is there a better way ...

Recommended Posts

Wget fails during install with pyenv
Install python with pyenv
Install python2.x on catalina with pyenv
How to install Anaconda with pyenv
Install Python as a Framework with pyenv
I wanted to install Python 3.4.3 with Homebrew + pyenv
Install pyenv on mac
Install pip, pyenv, BeautifulSoup4
Install pyenv and pyenv-virtualenv
Error with pip install
Install python (pyenv, pyenv-virtualenv)
Install Voluptuous with Python 2.5
Install the latest stable Python with pyenv (both 2 and 3)
Install torch-scatter with PyTorch 1.7
Build python3.x with pyenv
Install pyenv on OSX
Install scikit.learn with pip
When pip install fails
How to install Python2.7 python3.5 with pyenv (on RHEL5 CentOS5) (2016 Nov)
[CentOS7] Install anaconda using pyenv
Install Keras (used with Anaconda)
When moss with pip install
When pyenv install BUILD FAILED
Install external libraries with Python
Install github repository with pip
Install pyenv from Homebrew, install Python from pyenv
python with pyenv and venv