Skip to content

Commit

Permalink
Fix netpol startup when flannel is disabled
Browse files Browse the repository at this point in the history
Don't break out of the poll loop if we can't get the node, RBAC might not be ready yet.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
  • Loading branch information
brandond committed Feb 26, 2024
1 parent fae0d99 commit 86f1021
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/agent/netpol/netpol.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func Run(ctx context.Context, nodeConfig *config.Node) error {
node, err := client.CoreV1().Nodes().Get(ctx, nodeConfig.AgentConfig.NodeName, metav1.GetOptions{})
if err != nil {
logrus.Errorf("Error getting the node object: %v", err)
return false, err
return false, nil
}
// Check for the uninitialized taint that should be removed by cloud-provider
// If there is no cloud-provider, the taint will not be there
Expand Down

0 comments on commit 86f1021

Please sign in to comment.