【问题标题】:Letsencrypt ssl installation issue in digitalocean ubuntu 16.0 for flask application用于烧瓶应用程序的 digitalocean ubuntu 16.0 中的 Letsencrypt ssl 安装问题
【发布时间】:2020-06-05 05:06:20
【问题描述】:

当我安装letsencrypt的ssl时出现问题;我在 digitalocean 和 ubuntu 16.4 上将 apache 用于烧瓶应用程序。我已经使用 python3 安装了 virtualenv。我也尝试了一些代码

第 1347 和 1357 行: pip_version = StrictVersion(check_output([python, '-m', 'pip', '--version']) 经过 pip_version = StrictVersion(check_output(['pip', '--version']) 和命令 = [python, '-m', 'pip', 'install', '--no-index', '--no-deps', '-U'] 经过 command = ['pip', 'install', '--no-index', '--no-deps', '-U']

但没有任何积极的结果。我遇到的问题如下: '''

root@ubuntu-s-1vcpu-2gb-sgp1-01:/letsencrypt/letsencrypt# ./letsencrypt-auto --help
    Bootstrapping dependencies for Debian-based OSes... (you can skip this with --no-bootstrap)
    Get:1 http://mirrors.digitalocean.com/ubuntu bionic InRelease [242 kB]
    Hit:2 http://mirrors.digitalocean.com/ubuntu bionic-updates InRelease
    Hit:3 http://mirrors.digitalocean.com/ubuntu bionic-backports InRelease
    Hit:4 http://security.ubuntu.com/ubuntu bionic-security InRelease
    Fetched 242 kB in 1s (455 kB/s)
    Reading package lists... Done
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    augeas-lenses is already the newest version (1.10.1-2).
    libaugeas0 is already the newest version (1.10.1-2).
    libffi-dev is already the newest version (3.2.1-8).
    python is already the newest version (2.7.15~rc1-1).
    python-dev is already the newest version (2.7.15~rc1-1).
    python-virtualenv is already the newest version (15.1.0+ds-1.1).
    virtualenv is already the newest version (15.1.0+ds-1.1).
    ca-certificates is already the newest version (20190110~18.04.1).
    gcc is already the newest version (4:7.4.0-1ubuntu2.3).
    libssl-dev is already the newest version (1.1.1-1ubuntu2.1~18.04.6).
    openssl is already the newest version (1.1.1-1ubuntu2.1~18.04.6).
    0 upgraded, 0 newly installed, 0 to remove and 63 not upgraded.
    Creating virtual environment...
    usage: virtualenv [--version] [--with-traceback] [-v | -q] [--app-data APP_DATA] [--clear-app-data] 
   [--discovery {builtin}] [-p py] [--creator {builtin,cpython2-posix}] [--seeder {app-data,pip}] [--no- 
   seed] [--activators comma_sep_list]
                  [--clear] [--system-site-packages] [--symlinks | --copies] [--no-download | --download] 
    [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip] [- 
   -no-setuptools] [--no-wheel]
                  [--symlink-app-data] [--prompt prompt] [-h]
                  dest
   virtualenv: error: unrecognized arguments: --no-site-packages
   Traceback (most recent call last):
   File "<stdin>", line 27, in <module>
   File "<stdin>", line 19, in create_venv
   File "/usr/lib/python2.7/subprocess.py", line 190, in check_call
    raise CalledProcessError(retcode, cmd)
   subprocess.CalledProcessError: Command '['virtualenv', '--no-site-packages', '--python', 
   '/usr/bin/python2.7', '/opt/eff.org/certbot/venv']' returned non-zero exit status 2

'''

【问题讨论】:

    标签: python-3.x apache ssl flask lets-encrypt


    【解决方案1】:

    我找到了两种修复此错误的方法:

    1. 运行这些命令来升级 pip 然后重新安装 virtualenv:
    pip install --upgrade pip
    pip uninstall virtualenv
    pip install virtualenv
    
    1. 检查 virtualenv 的位置 - 它可能在 /usr/bin/virtualenv 中。如果它不存在,但有一个 virtualenv,后面有一个数字,如 virtualenv-2 或 virtualenv-2.7,则创建一个从 virtualenv 到这些现有文件之一的符号链接。

    【讨论】:

    • 谢谢。实际上,我已经找到了一个解决方案并尝试了对我有用的“etsencrypt.org”。
    猜你喜欢
    • 2019-01-25
    • 2015-04-18
    • 2018-06-30
    • 2012-12-01
    • 2013-06-04
    • 2019-08-07
    • 1970-01-01
    • 1970-01-01
    • 2020-10-05
    相关资源
    最近更新 更多