|
@ -359,11 +359,13 @@ get_volumes_for_container() { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
is_volume_used() { |
|
|
is_volume_used() { |
|
|
local volume="$1" |
|
|
|
|
|
|
|
|
local volume="$1" container_id src dst |
|
|
|
|
|
|
|
|
while read container_id; do |
|
|
while read container_id; do |
|
|
while read-0 src dst; do |
|
|
while read-0 src dst; do |
|
|
[ "$src" == "$volume" ] && return 0 |
|
|
|
|
|
|
|
|
[ "$src" == "$volume" ] && { |
|
|
|
|
|
return 0 |
|
|
|
|
|
} |
|
|
done < <(get_volumes_for_container "$container_id") |
|
|
done < <(get_volumes_for_container "$container_id") |
|
|
done < <(get_running_compose_containers) |
|
|
done < <(get_running_compose_containers) |
|
|
return 1 |
|
|
return 1 |
|
@ -1059,7 +1061,7 @@ run() { |
|
|
"$COMPOSE_LAUNCHER_BIN_OVERRIDE" \ |
|
|
"$COMPOSE_LAUNCHER_BIN_OVERRIDE" \ |
|
|
"$@") |
|
|
"$@") |
|
|
if [ "$E" != "0" ]; then |
|
|
if [ "$E" != "0" ]; then |
|
|
err "Unexpecte failure while trying to replace compose file option." |
|
|
|
|
|
|
|
|
err "Unexpected failure while trying to replace compose file option." |
|
|
return 1 |
|
|
return 1 |
|
|
fi |
|
|
fi |
|
|
set -- "${cmd_args[@]}" |
|
|
set -- "${cmd_args[@]}" |
|
|