2 servers under Argo Tunnel, how can they see each other?

Hi guys,

I’m happy with my Argo Tunnel configuration, but now I’d like to add a fail-over and load-balancing to my app. I’ve see that CloudFlare offers Load-Balancing with Argo Tunnels. Great.

But how can I activate the database replication between my 2 servers? Since there is no VPN, is there a way CloudFlare allow them to see each other via TCP so I can activate the replication?

Thanks,
Luca

They don’t need to see each other, once you create the various tunnels you use their host names for the pools in the LB configuration.

Thanks Matteo. So if I open a tcpip connection from server 1 to server 2, like that, would it work?

Not at all, not for Cloudflare’s LB at least, you are always free to do connections between the servers since you control them, but there will be no benefit for the Load Balancing. That is handled by the edge nodes at Cloudflare, do as I said before if you need failover, treat them as normal origins.

Since I’ve got a database to synchronize between the 2 nodes, I can I setup the replication if the 2 nodes can’t be seen?

Yeah, that of course is possible, you can do whatever you want with the machines. It’s just not a different setup for LB if Argo Tunnel is involved or not, that is all :slight_smile:

Hi Matteo, thanks for the quick responses. What’s the best way to find the servers? Is there a way to obtain the server list from the LB? In this way, I should be able to build something that scales with CloudFlare’s cluster without manual entering IP-addresses.

Also, this means the connection won’t be protected between servers. This should be done with a VPN, but it’s another layer. I was wondering if CloudFlare has something for this purpose. Otherwise I could build N tunnels, one for the public requests backed by a LB, and one tunnel per server:

public-tunnel
origin-server-1
origin-server-2
origin-server-N

And then if server-2 must open a secure connection to the server 1, it could just use ‘origin-server-1’. Also, in this way, it doesn’t need to know the real IP address.

The issue here is that AFAIK, only HTTP is supported on top of the tunnels, not just TCP. So I should write an HTTP layer on top of the replication protocol.

WDYT?
Luca

Hi, you already know the servers… why would you need to find them via Cloudflare? There is an API that returns the pool list for a Load Balancer, but those would be Argo Tunnel endpoints.

The best way would be probably to connect them directly, but I am not the right person to ask, nor this is the best place to ask these questions.

There is SQL and RDP in addition to HTTP with custom setups for all of them.

So, what’s the best place to ask this question?

StackOverflow or somewhere about the software stack you are using?