Invalid tls for local custom domain on ubuntu 22.04

1. Output of caddy version:

2. How I run Caddy:

a. System environment:

Ubuntu 22.04

b. Command:

 caddy reload

c. Service/unit/compose file:

Paste full file contents here.
Make sure backticks stay on their own lines,
and the post looks nice in the preview pane. -->

d. My complete Caddy config:

{
  debug
}

:80, *.boutic.store boutic.store {
  tls internal
  reverse_proxy * localhost:3000
}

3. The problem I’m having:

First of all, i am using the stable version of brave browser on ubuntu desktop 22.04.
So i am running a nextjs app on my ubuntu desktop and i’m trying have a secured ssl cert for my local custom domain(alias of localhost). I created a local caddyfile inside my app’s folder with the same content i posted above. Then reload caddy caddy reload to use it after i have started the app yarn dev. As you can see in the screenshot below, this the error i get when i visit any *.boutic.store, boutic.store url after freshly starting the local server. I’d have click the advanced button and proceed unsafely before the website will be available to navigate.
I also tried tls internal { on_demand } but i still got the same issue

4. Error messages and/or full log output:

Paste logs/commands/output here.
USE THE PREVIEW PANE TO MAKE SURE IT LOOKS NICELY FORMATTED.

5. What I already tried:

tls internal { on_demand }

6. Links to relevant resources:

Not all trust stores are currently supported. For some, like Firefox, you may have to install the root CA yourself.

Try running sudo caddy trust first. That might help.

1 Like

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