Forum not working after configuring CDN (ERR_CERT_COMMON_NAME_INVALID)

Hi,
I configured stackpath CDN.

I configured my DNS with the provided info:

TYPE NAME VALUE TTL
A @ 151.139.128.10 300
CNAME www f5i4i8k5.stackpathcdn.com 300

I edited app.yml and rebuilt the app:

  DISCOURSE_CDN_URL: https://www.unicyclist.com

But now the forum won’t load: NET::ERR_CERT_COMMON_NAME_INVALID

Any idea? :frowning:

edit: my CDN settings:

re edit: uuuh, now that’s a 503 error :thinking:

1 Like

So what is the forum domain?

Shouldn’t you use

  DISCOURSE_CDN_URL: https://f5i4i8k5.stackpathcdn.com

?

4 Likes

Your CDN URL is your Site’s Edge Address at Stackpath, which as @falco noted is top-right in your screenshot.

You’ve specified the site URL as the CDN URL, leaving the site referring to… itself? Like some bizarre CDNipede :bug:

3 Likes

Hi, thank you, I fixed my appl.yml. :+1:

The error 503 is gone, but I’ve still the SSL issue :thinking:

Here are the SSL settings in my stackpath panel, I don’t know if it’s of any usefulness:

This server couldn't prove that it's unicyclist.com;
its security certificate is from *.ssl.hwcdn.net.

So you have a VPS running on 151.139.128.10, a DNS entry for unicyclist.com of type A pointing to 151.139.128.10 and your app.yml hostname is set to unicyclist.com ?

So you will need to “create an additional certificate to use with custom Delivery Domains” using that blue button in the middle.

2 Likes

Well, I’m a bit lost (and reply precisely to your question at the end of the message)

I followed this #howto:
https://meta.discourse.org/t/enable-a-cdn-for-your-discourse/14857

  1. The CNAME , which is the “friendly” name for your CDN that you’ll set up in your DNS, e.g. discourse-cdn.example.com
  2. The CDN URL , which is the “unfriendly” name for where the cached CDN assets will be coming from via the CDN’s worldwide network of distributed servers. It will look like 637763234.cdn-provider.com

Stackpath told me to add this in my DNS (the screenshot is from my stackpath configuration steps):

The CNAME entry being www, I assumed that the “friendly” name for my CDN would be www.unicyclist.com.

Then, still following the howto where the “friendly” name is added to the app.yml:

Uncomment the CDN line in your app.yml and update it with the CNAME you just set up in your DNS:

## the origin pull CDN address for this Discourse instance
DISCOURSE_CDN_URL: //discourse-cdn.example.com

I did the same and I set DISCOURSE_CDN_URL to www.uncyclist.com

So I don’t quite understand why I should set the “unfriendly” name in my app.yml when the howto tell me the opposite.

As for the IP and domains:

My VPS IP is 95.217.21.71.
The A entry that I added following stackpath’s configuration steps is their own IP (as I understand it).
My app.yml hostname is unicyclist.com.

Oh, I’ll have a look at this!

Yup: that was that. Thanks guys!

1 Like

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