mirror of
https://github.com/tailscale/tailscale.git
synced 2025-02-18 02:48:40 +00:00
cmd/k8s-operator: remove unnecessary timed requeue.
Previously, we had to do blind timed requeues while waiting for the tailscale hostname, because we looked up the hostname through the API. But now the proxy container image writes back its hostname to the k8s secret, so we get an event-triggered reconcile automatically when the time is right. Updates #502 Signed-off-by: David Anderson <danderson@tailscale.com>
This commit is contained in:
parent
d857fd00b3
commit
835a73cc1f
@ -380,7 +380,7 @@ func (a *ServiceReconciler) Reconcile(ctx context.Context, req reconcile.Request
|
||||
if err := a.Status().Update(ctx, svc); err != nil {
|
||||
return reconcile.Result{}, fmt.Errorf("failed to update service status: %w", err)
|
||||
}
|
||||
return reconcile.Result{RequeueAfter: 10 * time.Second}, nil
|
||||
return reconcile.Result{}, nil
|
||||
}
|
||||
|
||||
logger.Debugf("setting ingress hostname to %q", tsHost)
|
||||
|
@ -60,7 +60,7 @@ func TestLoadBalancerClass(t *testing.T) {
|
||||
},
|
||||
})
|
||||
|
||||
expectRequeue(t, sr, "default", "test")
|
||||
expectReconciled(t, sr, "default", "test")
|
||||
|
||||
fullName, shortName := findGenName(t, fc, "default", "test")
|
||||
|
||||
@ -394,7 +394,7 @@ func TestLBIntoAnnotation(t *testing.T) {
|
||||
},
|
||||
})
|
||||
|
||||
expectRequeue(t, sr, "default", "test")
|
||||
expectReconciled(t, sr, "default", "test")
|
||||
|
||||
fullName, shortName := findGenName(t, fc, "default", "test")
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user