Caddy should listen for IPv4 traffic

Hi team,

I am running openvidu in Linux, latest (3.1.0) docker version.
Deployment in compliance with the documentation.

I cannot reach the server, since it does not listen at IPv4 traffic.

This is what the logs say:

{“level”:“info”,“ts”:1742899326.4948359,“msg”:“using config from file”,“file”:“/config/caddy.yaml”}
{“level”:“info”,“ts”:1742899326.496607,“msg”:“adapted config to JSON”,“adapter”:“yaml”}
{“level”:“info”,“ts”:1742899326.497715,“msg”:“redirected default logger”,“from”:“stderr”,“to”:“stdout”}
{“level”:“warn”,“ts”:1742899326.4977381,“logger”:“admin”,“msg”:“admin endpoint disabled”}
{“level”:“warn”,“ts”:1742899326.498806,“logger”:“http.auto_https”,“msg”:“server is listening only on the HTTP port, so no automatic HTTPS will be applied to this server”,“server_name”:“http_redirect”,“http_port”:80}
{“level”:“info”,“ts”:1742899326.4988337,“logger”:“http.auto_https”,“msg”:“skipping automatic certificate management because one or more matching certificates are already loaded”,“domain”:“openvidu.xy-space.de”,“server_name”:“minio”}
{“level”:“info”,“ts”:1742899326.4988472,“logger”:“http.auto_https”,“msg”:“enabling automatic HTTP->HTTPS redirects”,“server_name”:“minio”}
{“level”:“info”,“ts”:1742899326.5007923,“logger”:“http.log”,“msg”:“server running”,“name”:“http_redirect”,“protocols”:[“h1”,“h2”,“h3”]}
{“level”:“info”,“ts”:1742899326.500842,“logger”:“http”,“msg”:“enabling HTTP/3 listener”,“addr”:“:9000”}
{“level”:“info”,“ts”:1742899326.5010471,“logger”:“http.log”,“msg”:“server running”,“name”:“minio”,“protocols”:[“h1”,“h2”,“h3”]}
{“level”:“info”,“ts”:1742899326.5010722,“logger”:“http.log”,“msg”:“server running”,“name”:“public”,“protocols”:[“h1”,“h2”,“h3”]}
{“level”:“debug”,“ts”:1742899326.5010881,“logger”:“layer4”,“msg”:“listening”,“address”:“tcp/[::]:1935”}
{“level”:“debug”,“ts”:1742899326.5010972,“logger”:“layer4”,“msg”:“listening”,“address”:“tcp/[::]:443”}
{“level”:“info”,“ts”:1742899326.5012317,“msg”:“autosaved config (load with --resume flag)”,“file”:“/root/.config/caddy/autosave.json”}
{“level”:“info”,“ts”:1742899326.501236,“msg”:“serving initial configuration”}
{“level”:“debug”,“ts”:1742899382.4041414,“logger”:“layer4”,“msg”:“matching”,“remote”:“89.11.20.117:26174”,“error”:“consumed all prefetched bytes”,“matcher”:“layer4.matchers.tls”,“matched”:false}
{“level”:“debug”,“ts”:1742899382.4042,“logger”:“layer4”,“msg”:“prefetched”,“remote”:“89.11.20.117:26174”,“bytes”:517}
{“level”:“debug”,“ts”:1742899382.4042437,“logger”:“layer4”,“msg”:“matching”,“remote”:“89.11.20.117:26174”,“matcher”:“layer4.matchers.tls”,“matched”:true}

netstat -tulpn gives me:

tcp6 0 0 :::443 :::* LISTEN 141102/caddy
udp 0 0 0.0.0.0:443 0.0.0.0:* 141347/livekit-server

I want caddy to listen for IPv4 requests as well, how to manage that???
Interestingly, livekit-server listens for IPv4 connections.

I defined the server name with intitial configuration, no IP address. Maybe I should define the IP instead?

Martin.

This is my output of netstat -tlpn in a single node deployment:

tcp        0      0 127.0.0.11:35027        0.0.0.0:*               LISTEN      -                   
tcp        0      0 0.0.0.0:7000            0.0.0.0:*               LISTEN      6967/redis-server * 
tcp        0      0 0.0.0.0:5349            0.0.0.0:*               LISTEN      6848/livekit-server 
tcp        0      0 127.0.0.1:9091          0.0.0.0:*               LISTEN      7096/ingress        
tcp        0      0 127.0.0.1:9100          0.0.0.0:*               LISTEN      6036/minio          
tcp        0      0 127.0.0.1:7980          0.0.0.0:*               LISTEN      7310/egress         
tcp        0      0 0.0.0.0:20000           0.0.0.0:*               LISTEN      5302/mongod         
tcp6       0      0 :::9090                 :::*                    LISTEN      7556/prometheus     
tcp6       0      0 :::9092                 :::*                    LISTEN      7096/ingress        
tcp6       0      0 :::9093                 :::*                    LISTEN      7310/egress         
tcp6       0      0 :::9095                 :::*                    LISTEN      6875/loki           
tcp6       0      0 :::9100                 :::*                    LISTEN      6036/minio          
tcp6       0      0 :::9101                 :::*                    LISTEN      6036/minio          
tcp6       0      0 :::9000                 :::*                    LISTEN      6227/caddy          
tcp6       0      0 :::8080                 :::*                    LISTEN      7096/ingress        
tcp6       0      0 :::7880                 :::*                    LISTEN      6227/caddy          
tcp6       0      0 :::7881                 :::*                    LISTEN      6848/livekit-server 
tcp6       0      0 :::7780                 :::*                    LISTEN      6848/livekit-server 
tcp6       0      0 :::7000                 :::*                    LISTEN      6967/redis-server * 
tcp6       0      0 :::6789                 :::*                    LISTEN      6848/livekit-server 
tcp6       0      0 :::6080                 :::*                    LISTEN      6060/node           
tcp6       0      0 :::5000                 :::*                    LISTEN      6496/./openvidu-das 
tcp6       0      0 :::3100                 :::*                    LISTEN      6875/loki           
tcp6       0      0 :::3000                 :::*                    LISTEN      7710/grafana        
tcp6       0      0 :::1945                 :::*                    LISTEN      7096/ingress        
tcp6       0      0 :::1935                 :::*                    LISTEN      6227/caddy          
tcp6       0      0 :::443                  :::*                    LISTEN      6227/caddy          
tcp6       0      0 :::80                   :::*                    LISTEN      6227/caddy          
tcp6       0      0 :::22                   :::*                    LISTEN      1/init              
tcp6       0      0 ::1:9100                :::*                    LISTEN      6036/minio 

And I am able to reach all of the services via IPv4.

Are you able to reach the service via IPv4? I have this setup in a machine with IPv4 and it is working fine.

Take a look to this for further info: Netstat shows tcp6 on ipv4 only host

Are you sure this is the reason you can’t reach the server?

Thank you!
And yes, you are right, mistake from my side by defining the turns server in a wrong way.
System is up and running as expected, sorry for taking your time
(maybe it would be helpful to point out that the turns server cannot be the same as the openvidu server). Keep your good work running!

2 Likes