1. Note : DNS should be valid when Let's Encrypt. is used.
[lake@DESKTOP-P55Q2H7 caddy_v1.0.0_linux_amd64]$ cat Caddyfile
DESKTOP-P55Q2H7.mshome.net
{
##tls self_signed
tls your@qq.com
}
[lake@DESKTOP-P55Q2H7 caddy_v1.0.0_linux_amd64]$ sudo ./caddy
[sudo] password for lake:
Activating privacy features...
Your sites will be served over HTTPS automatically using Let's Encrypt.
By continuing, you agree to the Let's Encrypt Subscriber Agreement at:
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf
Do you agree to the terms? (y/n): y
2020/06/17 19:08:06 [INFO] acme: Registering account for your@qq.com
2020/06/17 19:08:06 [INFO] [desktop-p55q2h7.mshome.net] acme: Obtaining bundled SAN certificate
2020/06/17 19:08:07 [INFO] [desktop-p55q2h7.mshome.net] AuthURL: https://acme-v02.api.letsencrypt.org/acme/authz-v3/5297540062
2020/06/17 19:08:07 [INFO] [desktop-p55q2h7.mshome.net] acme: use tls-alpn-01 solver
2020/06/17 19:08:07 [INFO] [desktop-p55q2h7.mshome.net] acme: Trying to solve TLS-ALPN-01
2020/06/17 19:08:08 [INFO] Unable to deactivated authorizations: https://acme-v02.api.letsencrypt.org/acme/authz-v3/5297540062
2020/06/17 19:08:08 [desktop-p55q2h7.mshome.net] failed to obtain certificate: acme: Error -> One or more domains had a problem:
[desktop-p55q2h7.mshome.net] acme: error: 400 :: urn:ietf:params:acme:error:dns :: DNS problem: NXDOMAIN looking up A for desktop-p55q2h7.mshome.net - check that a DNS record exists for this domain, url:
[lake@DESKTOP-P55Q2H7 caddy_v1.0.0_linux_amd64]$