ADDITIONAL CGROUPS BLKIO STATS

Currently github.com/docker/libcontainer/cgroups/fs.GetStats does not provide the following metrics:
blkio.io_wait_time, blkio.io_service_time, blkio.io_merged, and blkio.time.

This commits add these four metrics. The descriptions of the metrics are here: https://www.kernel.org/doc/Documentation/cgroups/blkio-controller.txt.

It also modifies blkio_test and stats_util_test to ensure that the metrics are parsed.

Docker-DCO-1.1-Signed-off-by: Abin Shahab <ashahab@altiscale.com> (github: ashahab-altiscale)
devices: filter /dev/console out of the node list

Fixed getDeviceNodes() so it won't add /dev/console to the device node
list.

This fixes an issue where containers wouldn't start if
/dev/console is a pts (which is the case when running docker inside
docker), because devpts inodes are special and cannot be created with
mknod: attempting to open the result of doing so will return EIO.

Since later libcontainer would attempt to open the file to mount --bind
over it and fail because of the EIO error, the container wouldn't start
if the /dev/console was a pts, which is the case inside a docker
that was started from a pts.

getDeviceNodes() already filters pts so this change is consistent
with the current behavior.

Signed-off-by: Alejandro Ojeda <alex@x3y.org>
modified devices: filter /dev/console out of...

Applied crosbymichael's suggested changes

Signed-off-by: Alejandro Ojeda <alex@x3y.org>
Merge pull request #235 from alexoj/master

devices: filter /dev/console out of the node list
ErrNotSupportedPlatform is undefined define it

Signed-off-by: Harshavardhana <fharshav@redhat.com>
Merge pull request #236 from harshavardhana/undefined

ErrNotSupportedPlatform is undefined define it
Allow IPC namespace to be shared between containers or with the host

Some workloads rely on IPC for communications with other processes.  We
would like to split workloads between two container but still allow them
to communicate though shared IPC.

This patch allows us to mimic the --net code to allow --ipc=host to not split off
the IPC Namespace.  ipc=container:CONTAINERID to share ipc between containers

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Fix link re contributing in README following renaming in 9b10e7f
Merge pull request #238 from lucafavatella/contributing

Fix link re contributing in README
Only fetch network stats we use.

The dynamic version using WalkPath() was expensive and we only used some
of the stats anyways.

Signed-off-by: Victor Marmol <vmarmol@google.com>
Merge pull request #243 from ashahab-altiscale/242-additional-blkio-stats

ADDITIONAL CGROUPS BLKIO STATS
Merge pull request #244 from vmarmol/net-stats

Only fetch network stats we use.
Merge branch 'unreserve' of https://github.com/rhatdan/libcontainer into rhatdan-unreserve
Add test for IPC host sharing

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Add test for ipc private and shared path

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
Merge pull request #245 from crosbymichael/share-ipc

Allow IPC namespace to be shared between containers or with the host
Mount /dev/mqueue by default

Need this for supporting Posix Message Queues

man mq_overview

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Merge pull request #246 from rhatdan/mqueue

Mount /dev/mqueue by default
Add new interfaces for label/selinux

We need the ability when using --ipc container:ID to match the SELinux label of the
container that the new container is sharing a label with.

Also add the ability to get the option to disable SELinux labeling for a container.

Docker-DCO-1.1-Signed-off-by: Dan Walsh <dwalsh@redhat.com> (github: rhatdan)
Merge pull request #247 from rhatdan/selinux

Add new interfaces for label/selinux