telegraf/testutil/testutil.go

13 lines
204 B
Go
Raw Normal View History

2015-07-07 01:21:46 +00:00
package testutil
import "os"
var localhost = "localhost"
func GetLocalHost() string {
if dockerHostVar := os.Getenv("DOCKER_HOST"); dockerHostVar != "" {
return dockerHostVar
}
return localhost
}