我想在带有 Ubuntu 16.04 映像的docker环境中安装certbot:
例如:
docker run -it ubuntu:16.04 /bin/bash
Run Code Online (Sandbox Code Playgroud)
当我在容器内时,安装 certbot 的最直接方法不起作用,因为它需要用户干预:
apt-get update && \
apt-get install -y software-properties-common && \
add-apt-repository -y -u ppa:certbot/certbot && \
apt-get install -y certbot
Run Code Online (Sandbox Code Playgroud)
问题是tzdata,这个交互式对话框停止了:
Extracting templates from packages: 100%
Preconfiguring packages ...
Configuring tzdata
------------------
Please select the geographic area in which you live. Subsequent configuration
questions will narrow this down by presenting a list of cities, representing
the time zones in which they …Run Code Online (Sandbox Code Playgroud) 我安装了 Ubuntu 14.04.5 LTS。它最近变得无法验证现代的 Let's Encrypt 证书。当前版本ca-certificates是20160104ubuntu0.14.04.1. apt search ca-certificates告诉我该软件包可以升级到20170717~14.04.2from trusty-updates,但我认为这可能不够现代。
我看到ca-certificates版本20210119~18.04.2在bionic-updates. 是否可以在不破坏系统的情况下安装它?有没有更好的办法?谢谢。
我使用带有 Nginx 和 Certbot 的 Ubuntu 16.04。
我尝试执行,例如:
certbot -v
certbot -V
certbot --version
man certbot
Run Code Online (Sandbox Code Playgroud)
没有人给出任何相关的输出。我怎么知道我的 Ubuntu 中当前安装的版本?
要从 LetsEncrypt 获取通配符 SSL 证书,您需要根据https://community.letsencrypt.org/t/acme-v2-production-environment-wildcards/55578运行 certbot 0.22 或更高版本
我已经从 apt 安装了 certbot 使用
sudo apt-get install certbot
Run Code Online (Sandbox Code Playgroud)
然而,报告:
certbot 已经是最新版本 (0.17.0-2)。
如何将 certbot 升级到支持通配符证书的版本?
我试过了
sudo apt-get remove python-certbot-apache
sudo apt-get purge --auto-remove python-certbot-apache
sudo apt-get remove python3-certbot-apache
sudo apt-get purge --auto-remove python3-certbot-apache
Run Code Online (Sandbox Code Playgroud)
但是当我运行命令时certbot它仍然被识别。我怎样才能完全删除它,因此,键入该命令就像任何无法识别的命令一样。
我以前在 Ubuntu 上安装了 Certbot,但我相信该软件包尚不能用于此发行版,所以我相信我是从预构建的软件包安装的(也许,我真的不确定)。无论如何,现在我已经安装了 certbot 0.26.1:
certbot --version
certbot 0.26.1
Run Code Online (Sandbox Code Playgroud)
我尝试使用这里的指南安装它:https : //certbot.eff.org/lets-encrypt/ubuntubionic-nginx
以下是当前系统的一些输出:
apt-get install python-certbot-nginx
python-certbot-nginx is already the newest version (0.28.0-1+ubuntu18.04.1+certbot+3).
certbot --version
certbot 0.26.1
which certbot
/usr/bin/certbot
dpkg-query -L python-certbot-nginx
/.
/usr
/usr/share
/usr/share/doc
/usr/share/doc/python-certbot-nginx
/usr/share/doc/python-certbot-nginx/changelog.Debian.gz
/usr/share/doc/python-certbot-nginx/copyright
Run Code Online (Sandbox Code Playgroud)
所以在我看来,“python-certbot-nginx”包没有安装任何二进制文件。我在这里做错了吗?我有一些完全不同的软件包可以升级(例如 MySQL、PHP),但我只能在这个星期天升级这些软件包。但我相信这与我的问题完全无关。谢谢!
我已经在 Ubuntu 22.04 服务器上设置了 nginx 反向代理,并且已成功从 Lets Encrypt 获取 ssl 证书。两个密钥存储在这里:
/etc/letsencrypt/live/test.ddns.net/fullchain.pem;
/etc/letsencrypt/live/test.ddns.net/privkey.pem
Run Code Online (Sandbox Code Playgroud)
在我的默认 nginx 配置中,我有两个路径helloworld和portainer。两条路径都重定向到 docker 容器。
server {
listen 80;
listen [::]:80;
server_name test.ddns.net;
return 301 https://$host$request_uri;
}
server {
listen 443 ssl;
listen [::]:443 ssl;
server_name test.ddns.net;
ssl_certificate /etc/letsencrypt/live/test.ddns.net/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/test.ddns.net/privkey.pem;
location /helloworld {
proxy_pass http://localhost:32768;
}
location /portainer {
proxy_pass http://localhost:9000;
}
Run Code Online (Sandbox Code Playgroud)
helloworld 路径按预期工作,并使用 https 协议加载 html 页面(因此我的 ngnix 配置是正确的)。但portainer路径不是。我尝试了端口 9000、端口 8000、端口 9443。但都不起作用。我收到 404 错误,或者通过 http 发送的请求,而预期是 https,或者其他错误。有没有人有相同的设置并且能够帮助我?
谢谢。
我正在使用 Ubuntu 20.04 Server 设置云服务器。
我永远不会有很多访客,只有我的学生在做作业。
我想启用 https:// 访问。
我找到了这个页面。
certbot 是一个好方法吗?
我以前从未这样做过。
letsencrypt ×8
apt ×3
ssl ×3
https ×2
nginx ×2
server ×2
14.04 ×1
18.04 ×1
apache2 ×1
automation ×1
certificates ×1
docker ×1
versions ×1