Skip to content

Commit

Permalink
Merge pull request docker#18855 from rhatdan/volume-tmpfs
Browse files Browse the repository at this point in the history
No options to tmpfs is valid
  • Loading branch information
LK4D4 committed Dec 22, 2015
2 parents 81c8e4d + 89a775d commit 9c89e83
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions integration-cli/docker_cli_run_unix_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,9 @@ func (s *DockerSuite) TestRunTmpfsMounts(c *check.C) {
if out, _, err := dockerCmdWithError("run", "--tmpfs", "/run", "busybox", "touch", "/run/somefile"); err != nil {
c.Fatalf("/run directory not mounted on tmpfs %q %s", err, out)
}
if out, _, err := dockerCmdWithError("run", "--tmpfs", "/run:noexec", "busybox", "touch", "/run/somefile"); err != nil {
c.Fatalf("/run directory not mounted on tmpfs %q %s", err, out)
}
if out, _, err := dockerCmdWithError("run", "--tmpfs", "/run:noexec,nosuid,rw,size=5k,mode=700", "busybox", "touch", "/run/somefile"); err != nil {
c.Fatalf("/run failed to mount on tmpfs with valid options %q %s", err, out)
}
Expand Down
1 change: 1 addition & 0 deletions pkg/mount/flags.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ func parseOptions(options string) (int, string) {
func ParseTmpfsOptions(options string) (int, string, error) {
flags, data := parseOptions(options)
validFlags := map[string]bool{
"": true,
"size": true,
"mode": true,
"uid": true,
Expand Down

0 comments on commit 9c89e83

Please sign in to comment.