What's the difference between "volumeDevices" vs "volumeMounts" with k8s v1.13

12/14/2018

Running kubectl explain pod.spec.containers shows:

   volumeDevices    <[]Object>
     volumeDevices is the list of block devices to be used by the container.
     This is a beta feature.

   volumeMounts <[]Object>
     Pod volumes to mount into the container's filesystem. Cannot be updated.

Is there a relationship between these two containers properties?

Note that kubectl version shows:

Client Version: version.Info{Major:"1", Minor:"13", GitVersion:"v1.13.0", GitCommit:"ddf47ac13c1a9483ea035a79cd7c10005ff21a6d", GitTreeState:"clean", BuildDate:"2018-12-03T21:04:45Z", GoVersion:"go1.11.2", Compiler:"gc", Platform:"linux/amd64"}

Server Version: version.Info{Major:"1", Minor:"13", GitVersion:"v1.13.0", GitCommit:"ddf47ac13c1a9483ea035a79cd7c10005ff21a6d", GitTreeState:"clean", BuildDate:"2018-12-03T20:56:12Z", GoVersion:"go1.11.2", Compiler:"gc", Platform:"linux/amd64"}

-- Abdennour TOUMI
kubernetes
linux-device-driver

1 Answer

12/14/2018

'volumeDevices' is part of a new beta feature in 1.13 that allows a pod to access a raw block volume instead of a mounted filesystem volume. This is useful for some advanced applications like databases that may have their own filesystem format.

You can find the official documentation here although it does not seem to be updated for 1.13 yet.

-- Michelle
Source: StackOverflow