Skip to content

Commit 2c2a655

Browse files
committed
add env variable to disable kernel version warning
Allow the user to set DOCKER_NOWARN_KERNEL_VERSION=1 to disable the warning for RHEL 6.5 and other distributions that don't exhibit the panics described in moby/moby#407.
1 parent a5af346 commit 2c2a655

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

github/docker/master/engine/engine.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,9 @@ func New(root string) (*Engine, error) {
7070
log.Printf("WARNING: %s\n", err)
7171
} else {
7272
if utils.CompareKernelVersion(k, &utils.KernelVersionInfo{Kernel: 3, Major: 8, Minor: 0}) < 0 {
73-
log.Printf("WARNING: You are running linux kernel version %s, which might be unstable running docker. Please upgrade your kernel to 3.8.0.", k.String())
73+
if os.Getenv("DOCKER_NOWARN_KERNEL_VERSION") == "" {
74+
log.Printf("WARNING: You are running linux kernel version %s, which might be unstable running docker. Please upgrade your kernel to 3.8.0.", k.String())
75+
}
7476
}
7577
}
7678
if err := os.MkdirAll(root, 0700); err != nil && !os.IsExist(err) {

0 commit comments

Comments
 (0)