lets-encrypt - Certbot 未创建 .well-known/acme-challenges 文件
问题描述
我的域名是:
monxas.ninja
我运行了这个命令:
sudo certbot --apache --debug-challenges
它产生了这个输出:
Obtaining a new certificate
/usr/lib/python3/dist-packages/josepy/jwa.py:107: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
signer = key.signer(self.padding, self.hash)
Performing the following challenges:
http-01 challenge for monxas.ninja
Waiting for verification...
-------------------------------------------------------------------------------
Challenges loaded. Press continue to submit to CA. Pass "-v" for more info about
challenges.
-------------------------------------------------------------------------------
Press Enter to Continue
/usr/lib/python3/dist-packages/josepy/jwa.py:107: CryptographyDeprecationWarning: signer and verifier have been deprecated. Please use sign and verify instead.
signer = key.signer(self.padding, self.hash)
Cleaning up challenges
Failed authorization procedure. monxas.ninja (http-01): urn:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from http://monxas.ninja/.well-known/acme-challenge/Wt_CvapZhIJt3EDdoIjop4Lun7V4B_JpWmnpyMxz7es: "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\n<html><head>\n<title>404 Not Found</title>\n</head><body>\n<h1>Not Found</h1>\n<p"
IMPORTANT NOTES:
- The following errors were reported by the server:
Domain: monxas.ninja
Type: unauthorized
Detail: Invalid response from
http://monxas.ninja/.well-known/acme-challenge/Wt_CvapZhIJt3EDdoIjop4Lun7V4B_JpWmnpyMxz7es:
"<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML
2.0//EN\">\n<html><head>\n<title>404 Not
Found</title>\n</head><body>\n<h1>Not Found</h1>\n<p"
我的网络服务器是(包括版本):
Apache version 2.4.25
我的网络服务器运行的操作系统是(包括版本):
Raspbian GNU/Linux 9
我可以登录到我机器上的 root shell(是或否,或者我不知道):
yes
我正在使用控制面板来管理我的网站(否,或提供控制面板的名称和版本):
no
dns 记录是
A *.monxas.ninja 83.56.8.166 300
A monxas.ninja 83.56.8.166 300
我不使用 AAAA
此外,手动创建了众所周知的路径,您可以在此处看到:
解决方案
我想我可能已经找到了解决方案。无论如何,这是我的解决方案...
我倾向于查看续订文件并在其中找到了解决方案。我不知道这是如何或为什么不正确地创建的,但是两台服务器上的更新文件中的 webroot 都是错误的。当我更正它时,两次更新都按预期完成。
/etc/letsencrypt/renewal/www.server.com.conf
在 [[webroot_map]] 下查找条目
我希望这可以帮助别人。在考虑查看续订文件之前,我花了两天时间挠头。