ngrok / kubernetes-ingress-controller

The official ngrok Ingress Controller for Kubernetes
https://ngrok.com
MIT License
183 stars 20 forks source link

domain controller: run a driver sync after updating #342

Closed jrobsonchase closed 4 months ago

jrobsonchase commented 4 months ago

closes: #340

What

Ensures that the Status.LoadBalancer.Ingress[].Hostname field is set after the target CNAME is resolved on the Domain.

How

Add a call to Driver.updateIngressStatuses in the UpdateStoreHandler.Update method.

Breaking Changes

None

jrobsonchase commented 4 months ago

Is the driver Ingress-specific? I already saw it being shared by the ingress controller and moduleset controller, so I figured why not?

The ingress controller is already watching Domains among other objects: I think the issue is that when it watches these, it is just updating the store with the updates, but that isn't actually triggering an resync on any resources. I think this may actually be a more generic class of problem that we should handle.

Yeah, this was the first path I tried to go down and didn't really get anywhere with. That Watches for all of the other resources didn't seem to do anything that I could tell. I expected that the ingress controller would get notifications when any of those resources was updated, but that didn't seem to be the case.

Edit: Ohhhhh, I see now. It's the UpdateStoreHandler that gets called. Cool, lemme try making that propagate the changes.

jrobsonchase commented 4 months ago

Oops, did that let me merge before checks passed?