Skip to content

Commit

Permalink
Merge pull request google#388 from rjnagal/validate
Browse files Browse the repository at this point in the history
Fix cgroup root path detection.
  • Loading branch information
vishh committed Dec 22, 2014
2 parents 7f08c8f + c8eecef commit d3b24a3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion validate/validate.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ import (
"io/ioutil"
"log"
"net/http"
"path"
"strings"

"github.com/docker/libcontainer/cgroups"
Expand Down Expand Up @@ -188,7 +189,7 @@ func validateCgroupMounts() (string, string) {
out += desc
return Unknown, out
}
mnt = strings.TrimSuffix(mnt, "/cpu")
mnt = path.Dir(mnt)
if !utils.FileExists(mnt) {
out := fmt.Sprintf("Cgroup mount directory %s inaccessible.\n", mnt)
out += desc
Expand Down

0 comments on commit d3b24a3

Please sign in to comment.