-
Notifications
You must be signed in to change notification settings - Fork 5
/
config_provider.go
49 lines (40 loc) · 1.24 KB
/
config_provider.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package internal
// ProviderConfiguration is traefik-compatible configuration.
type ProviderConfiguration struct {
TCP TCPProviderConfiguration `yaml:"tcp"`
}
// TCPProviderConfiguration is traefik-compatible configuration.
type TCPProviderConfiguration struct {
Routers ExpectedRouters `yaml:"routers"`
Services ExpectedServices `yaml:"services"`
}
// ExpectedServices is traefik-compatible configuration.
type ExpectedServices struct {
APIServer Service `yaml:"kube-apiserver"`
}
// Service is traefik-compatible configuration.
type Service struct {
LoadBalancer LoadBalancerService `yaml:"loadBalancer"`
}
// LoadBalancerService is traefik-compatible configuration.
type LoadBalancerService struct {
Servers []Server `yaml:"servers"`
}
// Server is traefik-compatible configuration.
type Server struct {
Address string `yaml:"address"`
}
// ExpectedRouters is traefik-compatible configuration.
type ExpectedRouters struct {
Router1 Router `yaml:"Router-1"`
}
// Router is traefik-compatible configuration.
type Router struct {
Rule string `yaml:"rule"`
Service string `yaml:"service"`
TLS RouterTLS `yaml:"tls"`
}
// RouterTLS is traefik-compatible configuration.
type RouterTLS struct {
Passthrough bool `yaml:"passthrough"`
}