network_mode: "host"
disables most of docker’s networking features, including docker’s container dns.
Remove the network_mode: "host"
from the Caddy service/container in your docker-compose.yml
, run docker-compose -up -d
and your vaultwarden should start working as expected