Hi, all. So I am losing my mind over here. I recently paid for a domain through Njalla. I can route my email through it without any trouble, but then I thought I might like to self-host a personal website on it. I am using dietpi x86-64 on my homelab, a system on which I successfully host Jellyfin and Navidrome using Tailscale for remote access. I installed Wordpress and everything works just fine. The thing is, the moment I switch the site to an external URL, I simply cannot access it. I have added the A Records on Njalla for the domain to point at my server's public IP. I have opened ports 80 and 443 through UFW on the server, and pointed them to my the server's internal IP through the router. I have tried pointing Certbot at the URL, and it fails, returning the error that it couldn't fetch a file from /.well-known/acme-challenge (although it does show that the URL is pointing at the correct IP). I have changed my router settings to assign a static internal IP to the server.

I am at a loss. I'm sure it's something really easy and simple that I'm missing, but I cannot find what it is for the life of me. Thank you in advance for any tips or advice.

you are viewing a single comment's thread
view the rest of the comments
[–] 3 points 6 months ago* (3 children)

Sounds good.

Hmm next you probably should confirm ports 80 and 443 are actually reachable from the internet.

Use an online port checker like https://canyouseeme.org/

After that you should check your apache config like somebody else already suggested. I haven't used apache in a while but if I remember correctly:

Ensure it says: Listen 80 NOT: Listen 127.0.0.1:80

(and same with 443)

Also check your VirtualHost — it should look something like:

<VirtualHost *:80>
    ServerName yourdomain.com
    DocumentRoot /var/www/wordpress
    # ... other settings
</VirtualHost>

(and same with 443)

  • source
  • parent
  • hideshow 3 child comments
  • [–] [S] 2 points 6 months ago (2 children)

    Okay, great. So I checked all the config files, and everything seems to be in order there. But when I used an online port checker (I used yougetsignal.com), it said ports 80 and 443 are both closed. So the problem must be with my router, right?

  • source
  • parent
  • hideshow 2 child comments
  • [–] 2 points 6 months ago* (1 child)

    The problem could be anywhere in between the internet and your server.

    Ofc. it could be your routet. But I think the following is more likely:

    It might also be your internet service provider that doesn't allow those ports for inbound connections.

    Or you're behind a CGNAT so your real external ip is different from the one you think it is. (look up online how to test this)

  • source
  • parent
  • hideshow 1 child comment
  • [–] [S] 2 points 6 months ago

    That was it! I was behind a CGNAT! Thank you so much. I created a Cloudflare tunnel, and boom. I am now able to access the domain from my phone without wifi. Thank you, thank you, thank you. I still have some configuration to do, but the main issue has been resolved. You are an angel.

  • source
  • parent