Implement DCC streaming

This commit is contained in:
Ken-Håvard Lieng 2020-05-20 07:21:12 +02:00
parent 973578bb49
commit e33b9f05e4
15 changed files with 407 additions and 218 deletions

View file

@ -14,12 +14,12 @@ type Config struct {
Dev bool
HexIP bool
VerifyCertificates bool `mapstructure:"verify_certificates"`
Autoget bool
Headers map[string]string
Defaults Defaults
HTTPS HTTPS
LetsEncrypt LetsEncrypt
Auth Auth
DCC DCC
}
type Defaults struct {
@ -65,6 +65,17 @@ type Provider struct {
Secret string
}
type DCC struct {
Enabled bool
Autoget Autoget
}
type Autoget struct {
Enabled bool
Delete bool
DeleteAfter time.Duration `mapstructure:"delete_after"`
}
func LoadConfig() (*Config, chan *Config) {
viper.SetConfigName("config")
viper.AddConfigPath(storage.Path.ConfigRoot())