Commit 59274261 authored by David Ashpole's avatar David Ashpole

update cadvisor godeps to v0.27.2

parent bd28e6d0
...@@ -18,6 +18,7 @@ package crio ...@@ -18,6 +18,7 @@ package crio
import ( import (
"fmt" "fmt"
"path" "path"
"path/filepath"
"strconv" "strconv"
"strings" "strings"
"time" "time"
...@@ -142,6 +143,12 @@ func newCrioContainerHandler( ...@@ -142,6 +143,12 @@ func newCrioContainerHandler(
// get device ID from root, otherwise, it's going to error out as overlay // get device ID from root, otherwise, it's going to error out as overlay
// mounts doesn't have fixed dev ids. // mounts doesn't have fixed dev ids.
rootfsStorageDir = strings.TrimSuffix(rootfsStorageDir, "/merged") rootfsStorageDir = strings.TrimSuffix(rootfsStorageDir, "/merged")
switch storageDriver {
case overlayStorageDriver, overlay2StorageDriver:
// overlay and overlay2 driver are the same "overlay2" driver so treat
// them the same.
rootfsStorageDir = filepath.Join(rootfsStorageDir, "diff")
}
// TODO: extract object mother method // TODO: extract object mother method
handler := &crioContainerHandler{ handler := &crioContainerHandler{
......
...@@ -44,6 +44,7 @@ import ( ...@@ -44,6 +44,7 @@ import (
const ( const (
// The read write layers exist here. // The read write layers exist here.
aufsRWLayer = "diff" aufsRWLayer = "diff"
overlay2RWLayer = "diff"
// Path to the directory where docker stores log files if the json logging driver is enabled. // Path to the directory where docker stores log files if the json logging driver is enabled.
pathToContainersDir = "containers" pathToContainersDir = "containers"
...@@ -195,8 +196,10 @@ func newDockerContainerHandler( ...@@ -195,8 +196,10 @@ func newDockerContainerHandler(
switch storageDriver { switch storageDriver {
case aufsStorageDriver: case aufsStorageDriver:
rootfsStorageDir = path.Join(storageDir, string(aufsStorageDriver), aufsRWLayer, rwLayerID) rootfsStorageDir = path.Join(storageDir, string(aufsStorageDriver), aufsRWLayer, rwLayerID)
case overlayStorageDriver, overlay2StorageDriver: case overlayStorageDriver:
rootfsStorageDir = path.Join(storageDir, string(storageDriver), rwLayerID) rootfsStorageDir = path.Join(storageDir, string(storageDriver), rwLayerID)
case overlay2StorageDriver:
rootfsStorageDir = path.Join(storageDir, string(storageDriver), rwLayerID, overlay2RWLayer)
case zfsStorageDriver: case zfsStorageDriver:
status, err := Status() status, err := Status()
if err != nil { if err != nil {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment