Restrict traefik.toml to static configuration.

This commit is contained in:
Ludovic Fernandez 2019-07-15 10:22:03 +02:00 committed by Traefiker Bot
parent f49800e56a
commit 093658836e
78 changed files with 274 additions and 440 deletions

View file

@ -5,17 +5,3 @@ type ResourceLoader interface {
// Load populates cmd.Configuration, optionally using args to do so.
Load(args []string, cmd *Command) (bool, error)
}
type filenameGetter interface {
GetFilename() string
}
// GetConfigFile returns the configuration file corresponding to the first configuration file loader found in ResourceLoader, if any.
func GetConfigFile(loaders []ResourceLoader) string {
for _, loader := range loaders {
if v, ok := loader.(filenameGetter); ok {
return v.GetFilename()
}
}
return ""
}