Help me get a certificate from the docker

Hello

I tried to get a certificate using a docker in the local environment, but the error below occurred and it is not being processed.

IMPORTANT NOTES:
- The following errors were reported by the server:
  2020-08-13T08:32:06.082318691Z 
  Domain: api.localhost.com
  Type:   dns
  Detail: DNS problem: NXDOMAIN looking up TXT for
  _acme-challenge.api.localhost.com - check that a DNS record
  exists for this domain

I’m working on Windows 10 and the docker version is 19.

I checked the docking settings > network > dns server, but the dns settings did not work. Tell me the solution. Please.

1 Like

Is that the actual base domain name of the system?
If so, then global DNS can’t find the required TXT record to validate your request.
If not, then you need to understand how certificates work. You can’t request a certificate for a domain that you don’t own/control.

1 Like

localhost에서 C:\Windows\System32\drivers\etc\hosts 파일 수정을 이용한 접근은 certbot 인증서 생성이 불가능한 것인가요?

Do you own the domain “localhost.com” ?
If not, then you can’t request a certificate from that domain.

But to specifically answer your question: NO, there is nothing you can do in the local hosts file to overcome the lack of domain control.
The certificate validation is based on domain control (type DV).

2 Likes

I do not own the localhost.com domain. Maybe that’s why it wasn’t issued. Thank you.

Thank you for helping me with your precious time.

2 Likes

You can issue untrusted certificates for whatever domain you want, though: https://github.com/jsha/minica

2 Likes

Thank you. I’ll try using temporary ssl the way you told me.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.