Skip to content
Merged
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
10 changes: 6 additions & 4 deletions src/utils/container.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1718,8 +1718,9 @@ if [ -n "$AVOCADO_EXT_PATH_MOUNTS" ]; then
target_path="$EXT_PREFIX/$ext_name"

if [ -d "$mnt_path" ]; then
# Clear any stale files from a previous source type (e.g. package -> path switch)
rm -rf "$target_path"
# Create target if it doesn't exist. Avoid rm -rf because parallel
# containers share this volume and would race on the same paths.
# Stale package-sourced files are harmless — bindfs overlays them.
mkdir -p "$target_path"
if [ -n "$AVOCADO_HOST_UID" ] && [ -n "$AVOCADO_HOST_GID" ]; then
if [ "$AVOCADO_HOST_UID" = "0" ] && [ "$AVOCADO_HOST_GID" = "0" ]; then
Expand Down Expand Up @@ -1967,8 +1968,9 @@ if [ -n "$AVOCADO_EXT_PATH_MOUNTS" ]; then
target_path="$EXT_PREFIX/$ext_name"

if [ -d "$mnt_path" ]; then
# Clear any stale files from a previous source type (e.g. package -> path switch)
rm -rf "$target_path"
# Create target if it doesn't exist. Avoid rm -rf because parallel
# containers share this volume and would race on the same paths.
# Stale package-sourced files are harmless — bindfs overlays them.
mkdir -p "$target_path"
if [ -n "$AVOCADO_HOST_UID" ] && [ -n "$AVOCADO_HOST_GID" ]; then
if [ "$AVOCADO_HOST_UID" = "0" ] && [ "$AVOCADO_HOST_GID" = "0" ]; then
Expand Down
Loading