I'm trying to run the certbot-auto --apache command on my Ubuntu server but I'm running into this error:
Creating virtual environment...
Traceback (most recent call last):
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 1495, in
main()
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 537, in main
use_setuptools=options.use_setuptools)
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 628, in create_environment
install_distribute(py_executable, unzip=unzip_setuptools)
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 364, in install_distribute
_install_req(py_executable, unzip, distribute=True)
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 337, in _install_req
cwd=cwd)
File "/usr/lib/pymodules/python2.6/virtualenv.py", line 598, in call_subprocess
% (cmd_desc, proc.returncode))
OSError: Command /opt/eff.org/certbot/venv/bin/python2 -c "#!python
"""Bootstrap distribu...1:])
" --always-copy -U distribute failed with error code 1
I couldn't seem to find anyone else who had run into a similar issue and I'm kind of at a loss for what to do about it. Any help would be appreciated thanks
What version of Ubuntu is this? Is it one that is no longer supported by the Ubuntu developers?
We have recently removed Certbot support for Python 2.6 and it seems likely to me that if your only available Python version is 2.6, you might be on a distribution version whose developers consider it obsolete and recommend upgrading. But you might also be able to address the problem by installing a newer version of Python, if one is available.
Thanks for the reply. I am using an older, no longer supported, version of Ubuntu. I managed to upgrade Python to 2.7. When running the script now I get this:
Creating virtual environment...
Traceback (most recent call last):
File "/opt/eff.org/certbot/venv/lib/python2.7/site.py", line 67, in
import os
File "/opt/eff.org/certbot/venv/lib/python2.7/os.py", line 49, in
import posixpath as path
File "/opt/eff.org/certbot/venv/lib/python2.7/posixpath.py", line 17, in
import warnings
ImportError: No module named warnings
I would strongly suggest giving up and using a more modern host to terminate SSL for your old one, or at the very least use one of the (much, much) more simple to install ACME clients I recommended above.
It is in no uncertain terms an awful idea to try and use Certbot on a system this old. Even the Python ecosystem doesn’t support your OS anymore.
Anyway this is how I got certbot-auto working on Ubuntu Lucid / 10.04.
After doing that I'm still getting the "ImportError: No module named warnings" as before. Searching around this seems to be an issue when upgrading the virtual environment after upgrading python 2.6 to python 2.7.
I'm also seeing if my host is willing to upgrade me to a newer OS.