Addition of "--shm-size" to which size of /dev/shm is changed.

- Optional "--shm-size=" was added to the sub-command(run, create,and build).
- The size of /dev/shm in the container can be changed
  when container is made.
- Being able to specify is a numerical value that applies number,
  b, k, m, and g.
- The default value is 64MB, when this option is not set.
- It deals with both native and lxc drivers.

Signed-off-by: NIWA Hideyuki <niwa.hiedyuki@jp.fujitsu.com>
Upstream-commit: 5aeaf2a0c4236711e0981515d8627b30e22a1637
Component: engine
This commit is contained in:
NIWA Hideyuki
2015-11-20 09:24:18 +09:00
parent e1191bf537
commit 4581692a0e
16 changed files with 81 additions and 3 deletions
@@ -60,6 +60,7 @@ type Config struct {
Memory int64
MemorySwap int64
ShmSize int64
CPUShares int64
CPUPeriod int64
CPUQuota int64
@@ -508,6 +508,7 @@ func (b *Builder) create() (*daemon.Container, error) {
CgroupParent: b.CgroupParent,
Memory: b.Memory,
MemorySwap: b.MemorySwap,
ShmSize: b.ShmSize,
Ulimits: b.Ulimits,
Isolation: b.Isolation,
}