Add tokens in config
This commit is contained in:
@@ -4,6 +4,7 @@ type ConfigInterface interface {
|
||||
GetConfig() ZurgConfig
|
||||
GetVersion() string
|
||||
GetToken() string
|
||||
GetTokens() []string
|
||||
GetNumOfWorkers() int
|
||||
GetRefreshEverySecs() int
|
||||
GetRepairEveryMins() int
|
||||
@@ -34,8 +35,9 @@ type ConfigInterface interface {
|
||||
}
|
||||
|
||||
type ZurgConfig struct {
|
||||
Version string `yaml:"zurg" json:"-"`
|
||||
Token string `yaml:"token" json:"-"`
|
||||
Version string `yaml:"zurg" json:"-"`
|
||||
Token string `yaml:"token" json:"-"`
|
||||
Tokens []string `yaml:"tokens" json:"-"`
|
||||
|
||||
ApiTimeoutSecs int `yaml:"api_timeout_secs" json:"api_timeout_secs"`
|
||||
CanRepair bool `yaml:"enable_repair" json:"enable_repair"`
|
||||
@@ -60,8 +62,8 @@ type ZurgConfig struct {
|
||||
RetainRDTorrentName bool `yaml:"retain_rd_torrent_name" json:"retain_rd_torrent_name"`
|
||||
RetriesUntilFailed int `yaml:"retries_until_failed" json:"retries_until_failed"`
|
||||
ServeFromRclone bool `yaml:"serve_from_rclone" json:"serve_from_rclone"`
|
||||
Username string `yaml:"username" json:"username"`
|
||||
TorrentsCount int `yaml:"get_torrents_count" json:"get_torrents_count"`
|
||||
Username string `yaml:"username" json:"username"`
|
||||
}
|
||||
|
||||
func (z *ZurgConfig) GetConfig() ZurgConfig {
|
||||
|
||||
Reference in New Issue
Block a user