updated cadvisor deps

This commit is contained in:
David Ashpole
2017-03-10 10:09:25 -08:00
parent 1f5708d460
commit c3b24b75a3
5 changed files with 135 additions and 133 deletions

View File

@@ -252,9 +252,11 @@ func newDockerContainerHandler(
// split env vars to get metadata map.
for _, exposedEnv := range metadataEnvs {
for _, envVar := range ctnr.Config.Env {
splits := strings.SplitN(envVar, "=", 2)
if splits[0] == exposedEnv {
handler.envs[strings.ToLower(exposedEnv)] = splits[1]
if envVar != "" {
splits := strings.SplitN(envVar, "=", 2)
if len(splits) == 2 && splits[0] == exposedEnv {
handler.envs[strings.ToLower(exposedEnv)] = splits[1]
}
}
}
}