Skip to content

Commit

Permalink
Merge pull request #156 from backguynn/main
Browse files Browse the repository at this point in the history
remove default tags (use setDefault)
  • Loading branch information
backguynn committed Jul 9, 2024
2 parents dd80f61 + 5f0fd80 commit 9d5ef22
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cmd/loxilb-agent/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ type AgentConfig struct {
// external BGP Peers. This is a comma separated list e.g. IP1:ASID1,IP2:ASID2
ExtBGPPeers []string `yaml:"extBGPPeers,omitempty"`
// support BGP protocol
SetBGP uint16 `yaml:"setBGP,omitempty,default=0"`
SetBGP uint16 `yaml:"setBGP,omitempty"`
// Custom BGP Port
ListenBGPPort uint16 `yaml:"listenBGPPort,omitempty,default=179"`
ListenBGPPort uint16 `yaml:"listenBGPPort,omitempty"`
// Set eBGP multi-hop
EBGPMultiHop bool `yaml:"eBGPMultiHop"`
// loxilb loadbalancer mode
Expand Down
1 change: 0 additions & 1 deletion cmd/loxilb-agent/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ func newAgentCommand() *cobra.Command {
if err := opts.validate(args); err != nil {
klog.Errorf("Failed to options validate. err: %v", err)
os.Exit(255)

}
if err := run(opts); err != nil {
klog.Errorf("Error running agent. err: %v", err)
Expand Down
3 changes: 3 additions & 0 deletions cmd/loxilb-agent/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -291,4 +291,7 @@ func (o *Options) setDefaults() {
if o.config.ExtBGPPeers == nil {
o.config.ExtBGPPeers = []string{}
}
if o.config.ListenBGPPort == 0 {
o.config.ListenBGPPort = 179
}
}

0 comments on commit 9d5ef22

Please sign in to comment.