Skip to content

Commit

Permalink
Merge pull request #393 from l1b0k/fix/register_endpoint
Browse files Browse the repository at this point in the history
fix: adapt previous register endpoint config
  • Loading branch information
BSWANG authored Jul 25, 2022
2 parents 2d21c09 + e5996b7 commit 3806e48
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions types/controlplane/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,10 @@ func ParseAndValidate() (*Config, error) {
}
}

if c.RegisterEndpoint {
c.Controllers = append(c.Controllers, "endpoint")
}

err = validator.New().Struct(&c)
if err != nil {
return nil, err
Expand Down
1 change: 1 addition & 0 deletions types/controlplane/config_default.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ type Config struct {
WebhookPort int `json:"webhookPort" validate:"gt=0,lte=65535" mod:"default=4443"`
CertDir string `json:"certDir" validate:"required" mod:"default=/var/run/webhook-cert"`
LeaderElection bool `json:"leaderElection"`
RegisterEndpoint bool `json:"registerEndpoint"` //deprecated

NodeMaxConcurrent int `json:"nodeMaxConcurrent" validate:"gt=0,lte=10000" mod:"default=10"`
PodMaxConcurrent int `json:"podMaxConcurrent" validate:"gt=0,lte=10000" mod:"default=10"`
Expand Down

0 comments on commit 3806e48

Please sign in to comment.