I need some help to make bitwarden_rs respond to connection requests coming through a wireguard VPN network. I am building a mini hybrid/home cloud. I have rented an Ubuntu VM with public ip address. It’s used as a wireguard server. Then I spinned up a couple of Ubuntu VMs on my notebook (node1 and node2), wihch are set up as wireguard client nodes behind NAT. In reality these VMs are in one and the same network and they are able to ping and access each other both with and without wireguard VPN.
I ran bitwarden_rs on node1. I tried doing that by using the docker image, by extracting the binaries from a running container, by building bitwarden_rs locally (
bitwarden_rs 1.20.0-a82c0491) and installing it as a systemd service. Whatever I tried I always faced a blocking issue, i.e. when a HTTP request is sent through the wireguard VPN for bitwarden_rs to process, the connection request would not be accepted and would eventually time out. On the other hand, bitwarden_rs returns valid HTML documents, when I access the service from node2 over their common network or just curl the server from its own VM.
I tried tweaking the ROCKET_ADDRESS environment variable to allow connections from every host (0.0.0.0), from localhost only (127.0.0.1) where I set up a Caddy reverse proxy on the same VM. I tried to bind the server to a wireguard network address in the same way. The issue persists. The bitwarden_rs (or maybe Rocket under the hood) would not accept any connection requests through the wireguard network.
I have tried this same setup with running the python built-in web server on node1 instead of bitwarden_rs. It all worked end-to-end and across all network interfaces, the wireguard one included. This makes me think that the root cause is somehow related to bitwarden_rs.
Has anyone faced an issue like this? Can someone help me with troubleshooting it further?