From c552979e9286806e15b8c127c38ac6af2f284873 Mon Sep 17 00:00:00 2001 From: Gerrit Date: Thu, 12 Oct 2023 11:28:30 +0200 Subject: [PATCH] Reconcile firewall at least every three minutes. (#168) --- controllers/firewall_controller.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/controllers/firewall_controller.go b/controllers/firewall_controller.go index 6d46effa..df9f9d85 100644 --- a/controllers/firewall_controller.go +++ b/controllers/firewall_controller.go @@ -139,9 +139,11 @@ func (r *FirewallReconciler) Reconcile(ctx context.Context, req ctrl.Request) (c r.recordFirewallEvent(f, corev1.EventTypeNormal, "Reconciled", "nftables rules and statistics successfully") - r.Log.Info("successfully reconciled firewall") + r.Log.Info("successfully reconciled firewall, requeueing in 3 minutes") - return ctrl.Result{}, nil + return ctrl.Result{ + RequeueAfter: 3 * time.Minute, + }, nil } type firewallService struct {