1
0
mirror of https://github.com/mgerb/ServerStatus synced 2026-01-10 03:03:04 +00:00

feat: new features/improvements

- update dependencies
- add up/down time #14
- add workers with retry to help with spam
This commit is contained in:
2020-06-10 18:28:41 -05:00
parent 68bfed3f3b
commit f8d72bc297
9 changed files with 100 additions and 56 deletions

View File

@@ -16,16 +16,20 @@ type configStruct struct {
Token string `json:"Token"`
RoomIDList []string `json:"RoomIDList"`
RolesToNotify []string `json:"RolesToNotify"`
Servers []server `json:"Servers"`
Servers []Server `json:"Servers"`
GameStatus string `json:"GameStatus"`
PollingInterval time.Duration `json:"PollingInterval"`
BotPrefix string `json:"BotPrefix"`
}
type server struct {
type Server struct {
Name string `json:"Name"`
Address string `json:"Address"`
Port int `json:"Port"`
Online bool `json:"Online,omitempty"`
// OnlineTimestamp - time of when the server last came online
OnlineTimestamp time.Time
OfflineTimestamp time.Time
}
func Configure() {