Can't curl outside of localhost on LAN

1. Caddy version (caddy version):

2.4.3

2. How I run Caddy:

Caddyfile

a. System environment:

Arch linux, native, systemd

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 Caddyfile or JSON config:

:2015

respond "Hello World"

3. The problem I’m having:

I’m trying to access this server from another computer using

curl https://192.168.0.183:2015
curl 192.168.0.183:2015

4. Error messages and/or full log output:

curl: (28) Failed to connect to 92.168.0.193 port 80 after 131415 ms: Connection timed out

5. What I already tried:

I tried localhost instead of :2015
Also tried:
caddy file-server -browse
this worked fine
have trouble connecting with -domain and going to said domain, I have done port forwarding on ports 80 and 443
sudo caddy file-server -browse -domain gnupluslinux.club

6. Links to relevant resources:

I’m confused. You’re talking about both ports 2015 and 80/443 at the same time.

Could you try explaining the problem again? Please be as detailed as possible.

I got something like this to “work”

example.com {
  respond "hello"
}

But the issue I’m having right now is that I can’t access it on LAN but WAN works fine.
The issue is listed here Using Caddy as a reverse proxy in a home network and the solution is to make DNS which I’m going to do now

Solved my Issue. I apologize for being confusing.

What was your issue, ultimately?

It’s good forum etiquette to explain, so that future visitors that might land on this post don’t get left hanging with no conclusion.

2 Likes

My issue was that my router doesn’t support hairpin NAT.

1 Like

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