Newbie having trouble, NXDomain issues and Acme Challenge 404

My domain is: xevion.dev

I ran this command: sudo certbot --nginx -d xevion.dev -d www.xevion.dev

It produced this output: https://hastebin.com/dohugekilu.xml

My web server is: nginx version: nginx/1.14.0 (Ubuntu)

The operating system my web server runs on is:

Distributor ID: Ubuntu
Description:    Ubuntu 18.04.2 LTS
Release:        18.04
Codename:       bionic

My hosting provider is: DigitalOceans

I can login to a root shell on my machine: Yes

I’m using a control panel to manage my site:
I’m using DigitalOcean’s Control Panel to manage DNS and other settings,
but I ssh in to run commands and manage config files, if that makes sense.

The version of my client is: certbot 0.31.0

For background, I’m new to this, so I really am struggling to understand what’s going on. I know that my domain extension. .dev requires an SSL certificate, and my browser refuses to connect to any http:// prefixed urls, instead automatically adding an s for https:// concerning my site.

I’ve been looking into all the topics I could find that were similar, but mine may be dependent on faulty DNS settings (?) or something along those lines.

To get all the way here, I followed this guide on DigitalOceans for setting up a Flask server, the certbot part is all the way at the bottom.

You need to add a DNS A record in your Digital Ocean control panel for your www subdomain:

www.xevion.dev.    3600    IN     A     46.101.60.189

Add that, wait a few minutes, try again. If it’s still not working, then post the full output of Certbot.

2 Likes

Oh, I didn’t realize you had included the output as a separate link. Sorry about that.

To fix the second issue (the 404), you need to change your nginx configuration. Every time you have a line like this:

listen 80;

change it to this:

listen 80;
listen [::]:80; 

and then

systemctl reload nginx

The reason we are doing this is because you have IPv6 records setup for your domain, but nginx needs to be told that your website is available on IPv6, otherwise it shows the “default” nginx website.

3 Likes

Thanks so much. I’ve done both, added the subdomain to the records, as well as gotten my certificate after making those ipv6 changes!

image

3 Likes

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