Invalid response from / well-known/acme-challenge

My domain is: code-capture.com
It is being hosted on Azure VM, flask web app using Gunicorn over port 80
I ran this command: sudo certbot certonly --webroot

codecapture@CodeCaptureVM:~$ sudo certbot certonly --webroot
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator webroot, Installer None
Please enter in your domain name(s) (comma and/or space separated) (Enter 'c'
to cancel): code-capture.com
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for code-capture.com
Input the webroot for code-capture.com: (Enter 'c' to cancel): /home/codecapture/hoc-site/api
Waiting for verification...
Cleaning up challenges
Failed authorization procedure. code-capture.com (http-01): urn:ietf:params:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from http://code-capture.com/.well-known/acme-challenge/3bTzwa7ey_SDfkJZvwqRseC2w1SWCUKSVil8j7c_GNA [184.168.131.241]: "\n\n\n\n CodeCaptur"

IMPORTANT NOTES:

My web server is (include version): Flask, Gunicorn, React
The operating system my web server runs on is (include version): Azure VM(Ubuntu)

My hosting provider, if applicable, is: My App is hosted on Azure VM Linux instance, but the domain is registered using Azure Domain Services.

Please help

1 Like

You have to point your domain at your webserver using a DNS A record.

At the moment, you're using GoDaddy's "domain forwarding" or "domain masking" function, which just puts your server's IP address inside an HTML iframe.

This isn't compatible with being able to setup SSL, because your domain actually points to GoDaddy's webserver instead of your Azure one!

You need to do it this way instead of using domain forwarding: https://au.godaddy.com/help/add-an-a-record-19238

1 Like

Hi, But I'm not using GoDaddy for my domains. I'm using Azure Domain Services for my Domains.

1 Like

I don’t know whether Azure maybe resells GoDaddy, but they are definitely the registrar of record for your domain name.

You might be able to find those same domain forwarding options in Azure if that’s the case.

1 Like

Thanks for letting me know. I'll do this and get back to you.

1 Like

Hey @_az
I dont know what the problem is now
Done with the A records on azure domain services.


By checking this website, www.code-capture.com is working, but Code-capture.com is not.
What can be the issue?

Are you sure you set it to the right IP address in the A records?

It needs to be 52.140.73.53 for both the base domain and for www.

Okay! I'll set the IPs for both the domains same. There was some issue, I don't know why. Let me get back to you with that! Thanks