From 02c6110093ed23dd637a51611b0bce4fd4ab9ce9 Mon Sep 17 00:00:00 2001 From: Matthew Heon Date: Thu, 4 Apr 2019 11:48:23 -0400 Subject: Fix E2E tests The Commit test is blatantly wrong and testing buggy behavior. We should be commiting the destination, if anything - and more likely nothing at all. When force-removing volumes, don't remove the volumes of containers we need to remove. This can lead to a chicken and the egg problem where the container removes the volume before we can. When we re-add volume locks this could lead to deadlocks. I don't really want to deal with this, and this doesn't seem a particularly harmful quirk, so we'll let this slide until we get a bug report. Signed-off-by: Matthew Heon --- libpod/runtime_volume_linux.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libpod') diff --git a/libpod/runtime_volume_linux.go b/libpod/runtime_volume_linux.go index dcefcde4e..40040fc52 100644 --- a/libpod/runtime_volume_linux.go +++ b/libpod/runtime_volume_linux.go @@ -116,7 +116,7 @@ func (r *Runtime) removeVolume(ctx context.Context, v *Volume, force bool) error // containers? // I'm inclined to say no, in case someone accidentally // wipes a container they're using... - if err := r.removeContainer(ctx, ctr, false, true); err != nil { + if err := r.removeContainer(ctx, ctr, false, false); err != nil { return errors.Wrapf(err, "error removing container %s that depends on volume %s", ctr.ID(), v.Name()) } } -- cgit v1.2.3-54-g00ecf