We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents cab5b15 + 1ab2a14 commit 7af3a37Copy full SHA for 7af3a37
pkg/plugins/golang/v4/scaffolds/internal/templates/main.go
@@ -279,7 +279,11 @@ func main() {
279
WebhookServer: webhookServer,
280
HealthProbeBindAddress: probeAddr,
281
LeaderElection: enableLeaderElection,
282
- LeaderElectionID: "{{ hashFNV .Repo }}.{{ .Domain }}",
+ {{- if not .Domain }}
283
+ LeaderElectionID: "{{ hashFNV .Repo }}",
284
+ {{- else }}
285
+ LeaderElectionID: "{{ hashFNV .Repo }}.{{ .Domain }}",
286
+ {{- end }}
287
// LeaderElectionReleaseOnCancel defines if the leader should step down voluntarily
288
// when the Manager ends. This requires the binary to immediately end when the
289
// Manager is stopped, otherwise, this setting is unsafe. Setting this significantly
0 commit comments