如何解决Certbot或Let's Encrypt将多余的“ .com”添加到域
我的服务器具有多个域。 certbot对于其中所有功能都适用,但其中之一除外。 让我们以“ blog.domain.staging.com”为例来解决这个问题。
certbot certonly -t -n --dry-run --agree-tos --renew-by-default --email "${LE_EMAIL}" --webroot -w /usr/share/nginx/html -d blog.domain.staging.com
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator webroot,Installer None
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for blog.domain.staging.com
Using the webroot path /usr/share/nginx/html for all unmatched domains.
Waiting for verification...
Cleaning up challenges
Failed authorization procedure. blog.domain.staging.com (http-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to verify the domain :: Fetching https://blog.domain.staging.com.com/.well-known/acme-challenge/YWnMAB2mDZFl4-tEO1BCrKc3vP6yeAL2JVZP-A-BRV4: Error getting validation data
IMPORTANT NOTES:
- The following errors were reported by the server:
Domain: blog.domain.staging.com
Type: connection
Detail: Fetching
https://blog.domain.staging.com.com/.well-known/acme-challenge/YWnMAB2mDZFl4-tEO1BCrKc3vP6yeAL2JVZP-A-BRV4:
Error getting validation data
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. Additionally,please check that
your computer has a publicly routable IP address and that no
firewalls are preventing the server from communicating with the
client. If you're using the webroot plugin,you should also verify
that you are serving files from the webroot path you provided.
您可以看到主机名还有其他“ .com”,但我不知道为什么以及如何解决。
解决方法
nginx配置中有错字。从http重定向到https的链接带有附加的“ .com”。那是问题。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。