nginx 上的 Certbot 未在网站上创建 .well-known 目录

nginx 上的 Certbot 未在网站上创建 .well-known 目录

当我尝试使用 nginx 服务器上安装证书时sudo certbot certonly --webroot -w [my web root] -d [mywebsite]出现此错误:

   Domain: [mywebsite]
   Type:   unauthorized
   Detail: Invalid response from
   http://mywebsite/.well-known/acme-challenge/[key]
   [ip]: "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML
   4.01//EN\"\n
   \"http://www.w3.org/TR/html4/strict.dtd\">\n<html>\n\n<head>\n
   <title>[other code]"

   To fix these errors, please make sure that your domain name was
   entered correctly and the DNS A/AAAA record(s) for that domain
   contain(s) the right IP address.

显示的代码是我的索引页的开头,但是无效的 404 页面会出现 403 错误,并且不会重定向到索引。

相关内容