Skip to content

Commit

Permalink
Set LeaderElectionNamespace to PodNamespace
Browse files Browse the repository at this point in the history
Signed-off-by: Ali Aqel <[email protected]>
  • Loading branch information
aliaqel-stripe committed Jan 18, 2024
1 parent 3306ecb commit 327cb39
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions cmd/operator/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,13 +160,14 @@ func main() {
Cache: ctrlcache.Options{
DefaultNamespaces: namespaces,
},
HealthProbeBindAddress: probeAddr,
PprofBindAddress: profilingAddr,
LeaderElection: enableLeaderElection,
LeaderElectionID: "operator.keda.sh",
LeaseDuration: leaseDuration,
RenewDeadline: renewDeadline,
RetryPeriod: retryPeriod,
HealthProbeBindAddress: probeAddr,
PprofBindAddress: profilingAddr,
LeaderElection: enableLeaderElection,
LeaderElectionID: "operator.keda.sh",
LeaderElectionNamespace: kedautil.GetPodNamespace(),
LeaseDuration: leaseDuration,
RenewDeadline: renewDeadline,
RetryPeriod: retryPeriod,
})
if err != nil {
setupLog.Error(err, "unable to start manager")
Expand Down

0 comments on commit 327cb39

Please sign in to comment.