diff options
author | Matthew Heon <matthew.heon@pm.me> | 2019-09-24 15:57:17 -0400 |
---|---|---|
committer | Matthew Heon <matthew.heon@pm.me> | 2019-09-24 15:57:17 -0400 |
commit | d89414b1f0ca3fa2e9685681361c667960332f03 (patch) | |
tree | 74a22adfad49c627e1b730e99c23d937f21711de /test/e2e/run_volume_test.go | |
parent | 0000afc1af06b04ececeb91637bb3d80d6f47e14 (diff) | |
download | podman-d89414b1f0ca3fa2e9685681361c667960332f03.tar.gz podman-d89414b1f0ca3fa2e9685681361c667960332f03.tar.bz2 podman-d89414b1f0ca3fa2e9685681361c667960332f03.zip |
Handle conflict between volumes and --read-only-tmpfs
When a named volume is mounted on any of the tmpfs filesystems
created by read-only tmpfs, it caused a conflict that was not
resolved prior to this.
Fixes BZ1755119
Signed-off-by: Matthew Heon <matthew.heon@pm.me>
Diffstat (limited to 'test/e2e/run_volume_test.go')
-rw-r--r-- | test/e2e/run_volume_test.go | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test/e2e/run_volume_test.go b/test/e2e/run_volume_test.go index fc1998ab2..bc3a14b66 100644 --- a/test/e2e/run_volume_test.go +++ b/test/e2e/run_volume_test.go @@ -270,4 +270,14 @@ var _ = Describe("Podman run with volumes", func() { Expect(separateVolumeSession.ExitCode()).To(Equal(0)) Expect(separateVolumeSession.OutputToString()).To(Equal(baselineOutput)) }) + + It("podman read-only tmpfs conflict with volume", func() { + session := podmanTest.Podman([]string{"run", "--rm", "-t", "-i", "--read-only", "-v", "tmp_volume:/run", ALPINE, "touch", "/run/a"}) + session.WaitWithDefaultTimeout() + Expect(session.ExitCode()).To(Equal(0)) + + session2 := podmanTest.Podman([]string{"run", "--rm", "-t", "-i", "--read-only", "--tmpfs", "/run", ALPINE, "touch", "/run/a"}) + session2.WaitWithDefaultTimeout() + Expect(session2.ExitCode()).To(Equal(0)) + }) }) |