[make-initrd] [PATCH v1 08/41] fork pipeline: getimage step modified
Leonid Krivoshein
klark.devel at gmail.com
Fri Sep 24 18:56:14 MSK 2021
---
.../bootchain-getimage/data/lib/bootchain/getimage | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git
a/make-initrd/features/bootchain-getimage/data/lib/bootchain/getimage
b/make-initrd/features/bootchain-getimage/data/lib/bootchain/getimage
index 409ad14..49c5ebf 100755
--- a/make-initrd/features/bootchain-getimage/data/lib/bootchain/getimage
+++ b/make-initrd/features/bootchain-getimage/data/lib/bootchain/getimage
@@ -1,6 +1,6 @@
#!/bin/bash -efu
-. pipeline-sh-functions
+. bootchain-sh-functions
check_parameter GETIMAGE
url="$(get_parameter GETIMAGE)"
@@ -9,12 +9,13 @@ if [ -n "${url##file://*}" ]; then
# FIXME: make a better waiting for network
n=0
while [ "$n" != 5 ]; do
- ! wget -O "$datadir/image" "$url" ||
+ ! run wget -O "$datadir/image" -- "$url" ||
break
n=$(($n + 1))
sleep 3
done
else
- cp -f -- "${url#file://}" "$datadir/image"
+ run cp -Lf -- "${url#file://}" "$datadir/image"
fi
-run mount -o ro,loop "$datadir/image" "$destdir"
+
+run mount -o ro,loop -- "$datadir/image" "$destdir"
--
2.21.0
More information about the Make-initrd
mailing list