As far as I understand, you have two servers. One runs the web server, and you want both servers to run onion services that can access the web server.
An issue with running the onion service on one server and the web server on another is that the onion service will remove all of Tor's encryption, so you don't want to just send the plaintext traffic across the network to the web server.
One option for sending the traffic between two servers might be an SSH tunnel. For example if server A is running the web server and you want to securely send traffic from an onion service on server B, you could run
ssh -N -L 8080:127.0.0.1:8080 serverA on server B to set up a tunnel, and on server B also set up an onion service on port 8080 (example:
HiddenServicePort 80 127.0.0.1:8080). Any onion service traffic will then be tunneled through SSH to the web server on port 8080 on server A. All you need for this to work is to have SSH access from server B to server A.
If the SSH tunnel solution works fine, then you probably want something more permanent. In that case a Wireguard VPN would probably work better than an SSH tunnel.