add support for TLS via NewClientFromEnv(), remove dockerHost config param

This commit is contained in:
Bradley Cicenas
2017-03-09 22:57:12 +00:00
parent 03d4869361
commit 96b01eb3b9
2 changed files with 1 additions and 7 deletions

View File

@@ -4,7 +4,6 @@ import (
"sort"
"strings"
"github.com/bcicen/ctop/config"
"github.com/bcicen/ctop/metrics"
"github.com/fsouza/go-dockerclient"
)
@@ -22,7 +21,7 @@ type DockerContainerSource struct {
func NewDockerContainerSource() *DockerContainerSource {
// init docker client
client, err := docker.NewClient(config.GetVal("dockerHost"))
client, err := docker.NewClientFromEnv()
if err != nil {
panic(err)
}