Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Cloudflare Load Balancers #58

Open
adyanth opened this issue May 11, 2022 · 2 comments
Open

Support Cloudflare Load Balancers #58

adyanth opened this issue May 11, 2022 · 2 comments
Labels
enhancement New feature or request roadmap Roadmap Item

Comments

@adyanth
Copy link
Owner

adyanth commented May 11, 2022

Support adding the created Tunnels to existing/new Cloudflare Load Balancers, therefore reducing the manual step of doing it and recording it on the CR.

Requested by #1 (comment)

@adyanth adyanth added enhancement New feature or request roadmap Roadmap Item labels Jul 15, 2022
@christidis
Copy link

I am currently using 4 tunnels (each with size of 2 but this doesn't really matter) all sinked in the same Cloudflare Load Balancer. This is the suggested design for a really HA and Fault tolerant setup from Cloudflare's side.
cf-operator-tunnel-01
cf-operator-tunnel-02
cf-operator-tunnel-03
cf-operator-tunnel-04

It would be nice to be able to define more than one tunnels in each tunnelRef definition or provide a regex to match them all with a single manifest or something similar.

The current configuration is the following:

tunnelRef:
  kind: ClusterTunnel # Or Tunnel
  name: cf-operator-tunnel-01
  disableDNSUpdates: true

which means that I need to deduplicate all the TunnelBinding CRDs for each tunnel. Am I correct?

I added my comment here because having more than one tunnels is common when using a CF LB. But if you think I need to file a separate suggestion for this one, I can do that! Thanks.

@adyanth
Copy link
Owner Author

adyanth commented Jul 20, 2023

The way it is implemented currently is using a role/roleBinding strategy which does not reliably lend itself to having multiple tunnelRefs being used. Providing a regex would also have similar problems because of the way each tunnelBinding discovers a tunnel to configure.
Each tunnelBinding has labels of it's tunnel on it, so that when configuring, we can enumerate all the relevant tunnelBindings.

Implementing this would need a different way of looking up connected tunnelBindings for a given tunnel (effectively making a many to many lookup), which is not directly possible as of now. An idea would be to store all the linked tunnelBindings in the tunnel's status, but it needs to be tested out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request roadmap Roadmap Item
Projects
None yet
Development

No branches or pull requests

2 participants