update
This commit is contained in:
parent
f9df806b6d
commit
b236b68486
22 changed files with 288 additions and 36 deletions
15
user/wait-for-mount.sh
Normal file
15
user/wait-for-mount.sh
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
#!/bin/sh
|
||||
|
||||
set -eu
|
||||
|
||||
mountpoint_dir=$1
|
||||
attempt=0
|
||||
|
||||
while ! mountpoint -q "$mountpoint_dir"; do
|
||||
attempt=$((attempt + 1))
|
||||
if [ "$attempt" -ge 100 ]; then
|
||||
echo "Timed out waiting for mount: $mountpoint_dir" >&2
|
||||
exit 1
|
||||
fi
|
||||
sleep 0.1
|
||||
done
|
||||
Loading…
Add table
Add a link
Reference in a new issue