Fail and exit telegraf if no plugins are found loaded, issue #26

This commit is contained in:
Cameron Sparr 2015-08-06 16:22:24 -06:00
parent fc95e8401a
commit 38bbe7567a
1 changed files with 4 additions and 0 deletions

View File

@ -71,6 +71,10 @@ func main() {
if err != nil {
log.Fatal(err)
}
if len(plugins) == 0 {
log.Printf("Error: no plugins found, did you provide a config file?")
os.Exit(1)
}
if *fTest {
if *fConfig != "" {