virtcontainers: kata_agent: Handle several /dev/shm

The kata_agent.go code breaks after the first /dev/shm. But in case
several are defined, the agent will crash since other /dev/shm will
be wrongly configured in the OCI spec mounts.

Fixes #127

Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
Sebastien Boeuf 2018-03-28 08:44:40 -07:00
parent 08909b2213
commit 80996b3b40

View File

@ -570,8 +570,6 @@ func constraintGRPCSpec(grpcSpec *grpc.Spec) {
grpcSpec.Mounts[idx].Type = "tmpfs"
grpcSpec.Mounts[idx].Source = "shm"
grpcSpec.Mounts[idx].Options = []string{"noexec", "nosuid", "nodev", "mode=1777", "size=65536k"}
break
}
}
}