Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions e2etests/MODULE.bazel
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
bazel_dep(name = "rules_cc", version = "0.1.1")
bazel_dep(name = "rules_shell", version = "0.4.0")
bazel_dep(name = "rules_shell", version = "0.6.1")

git_repository = use_repo_rule("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")
git_repository(
name = "aosp_artifact",
commit = "385f9fae2a213ebb285d8a1a8dd041b1f92e6102",
commit = "9479ec22e5f0f12d55873c56980be5aad6fc2c75",
remote = "https://github.com/google/android-cuttlefish.git",
strip_prefix = "e2etests/orchestration/artifacts",
)
4 changes: 2 additions & 2 deletions e2etests/cvdr/cvdr_create_with_local_srcs_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ set -e -x
source ${TEST_SRCDIR}/_main/cvdr/common_utils.sh
validate_components

CVD_HOST_PKG=${TEST_SRCDIR}/+_repo_rules+aosp_artifact/cvd-host_package.tar.gz
CVD_HOST_PKG="${TEST_SRCDIR}/+git_repository+aosp_artifact/cvd-host_package.tar.gz"
if [ ! -f ${CVD_HOST_PKG} ]; then
echo "Cannot find CVD host package from ${CVD_HOST_PKG}"
exit 1
fi
IMAGE_ZIP=${TEST_SRCDIR}/+_repo_rules+aosp_artifact/images.zip
IMAGE_ZIP="${TEST_SRCDIR}/+git_repository+aosp_artifact/images.zip"
if [ ! -f "${IMAGE_ZIP}" ]; then
echo "Cannot find image zip file from ${IMAGE_ZIP}"
exit 1
Expand Down
7 changes: 7 additions & 0 deletions pkg/app/instances/docker.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import (
"github.com/docker/docker/api/types/mount"
"github.com/docker/docker/api/types/volume"
"github.com/docker/docker/client"
"github.com/docker/docker/errdefs"
)

const DockerIMType IMType = "docker"
Expand Down Expand Up @@ -470,6 +471,12 @@ func (m *DockerInstanceManager) deleteDockerVolumeIfNeeded(ctx context.Context,
}
for _, volume := range volumeListRes.Volumes {
if err := m.Client.VolumeRemove(ctx, volume.Name, true); err != nil {
if errdefs.IsConflict(err) {
// Bypass conflict error when the volume is in use, as there's
// a race for deleting volume when deleting multiple hosts
// simultaneously.
continue
}
return fmt.Errorf("failed to remove docker volume: %w", err)
}
}
Expand Down
Loading