Don't allow reload with old-style backend configurations.

This commit is contained in:
Joachim Bauch 2020-10-06 16:00:29 +02:00
parent f7ed6addb7
commit aa0191ef7e
No known key found for this signature in database
GPG key ID: 77C1D22D53E15F02

View file

@ -200,6 +200,11 @@ func getConfiguredHosts(backendIds string, config *goconf.ConfigFile) (hosts map
}
func (b *BackendConfiguration) Reload(config *goconf.ConfigFile) {
if b.compatBackend != nil {
log.Println("Old-style configuration active, reload is not supported")
return
}
if backendIds, _ := config.GetString("backend", "backends"); backendIds != "" {
configuredHosts := getConfiguredHosts(backendIds, config)