29 lines
373 B
Go
29 lines
373 B
Go
package haproxy
|
|
|
|
type Config struct {
|
|
LoadBalancers []LoadBalancer
|
|
}
|
|
|
|
type LoadBalancer struct {
|
|
Name string
|
|
IP string
|
|
Options Options
|
|
Ports []Port
|
|
}
|
|
|
|
type Options struct {
|
|
Frontend []string
|
|
Backend []string
|
|
DefaultServer string
|
|
}
|
|
|
|
type Port struct {
|
|
Port int
|
|
Servers []Server
|
|
}
|
|
|
|
type Server struct {
|
|
Name string
|
|
IP string
|
|
Port int
|
|
}
|