我实际上正在开发一个 web 应用程序,我使用 Reactjs
作为前端,使用 --- Golang
作为后端。这两个程序分别托管在 Google-Compute-Engine
上的 2 个虚拟机上。我想通过 https
为我的应用程序提供服务,所以我选择使用 Nginx
为生产中的前端提供服务。首先,我为 Nginx
创建了配置文件:
#version: nginx/1.14.0 (ubuntu)
server {
listen 80 default_server;
listen [::]:80 default_server;
root /var/www/banshee;
server_name XX.XXX.XX.XXX; #public IP of my frontend VM
index index.html;
location / {
try_files $uri /index.html =404;
}
}
对于这部分,一切都按预期工作,但之后我想按照 本教程 通过 https
为我的应用程序提供服务。我安装了软件包 software-properties-common
, python-certbot-apache
和 certbot
但是当我尝试
sudo cerbot --nginx certonly
我收到以下消息:
gdes@frontend:/etc/nginx$ sudo certbot --nginx certonly
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Could not choose appropriate plugin: The requested nginx plugin does not appear to be installed
The requested nginx plugin does not appear to be installed
我在 Google 和此处进行了一些搜索,但我仍然无法确定缺少哪个插件或其他解决此问题的方法。
有人有帮助我的想法吗?
非常感谢 :)
原文由 G.D 发布,翻译遵循 CC BY-SA 4.0 许可协议
我试图使用 certbot 为我的子域创建 let’sencrypt 证书并遇到以下问题。 命令 :
问题 :
解决方案:
Ubuntu 20+
早期版本