forked from cherryservers/cherrygo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
bgp.go
31 lines (27 loc) · 929 Bytes
/
bgp.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
package cherrygo
type ProjectBGP struct {
Enabled bool `json:"enabled,omitempty"`
LocalASN int `json:"local_asn,omitempty"`
}
type ServerBGP struct {
Enabled bool `json:"enabled"`
Available bool `json:"available,omitempty"`
Status string `json:"status,omitempty"`
Routers int `json:"routers,omitempty"`
Connected int `json:"connected,omitempty"`
Limit int `json:"limit,omitempty"`
Active int `json:"active,omitempty"`
Routes []BGPRoute `json:"routes,omitempty"`
Updated string `json:"updated,omitempty"`
}
type BGPRoute struct {
Subnet string `json:"subnet,omitempty"`
Active bool `json:"active,omitempty"`
Router string `json:"router,omitempty"`
Age string `json:"age,omitempty"`
Updated string `json:"updated,omitempty"`
}
type RegionBGP struct {
Hosts []string `json:"hosts,omitempty"`
Asn int `json:"asn,omitempty"`
}