Merge branch 'srm-mount' into 'master'

srm patch: simplify mount command

See merge request fdupoux/sysresccd-src!71
This commit is contained in:
Francois Dupoux 2020-08-05 05:58:16 +00:00
commit 78d97abd5e

View file

@ -1,5 +1,5 @@
diff --git a/archiso/initcpio/hooks/archiso b/archiso/initcpio/hooks/archiso
index 5c56561..69546d7 100644
index 5c56561..f99a617 100644
--- a/archiso/initcpio/hooks/archiso
+++ b/archiso/initcpio/hooks/archiso
@@ -72,6 +72,44 @@ _mnt_sfs() {
@ -31,7 +31,7 @@ index 5c56561..69546d7 100644
+ # _mnt_dev() will launch shell in case of error
+ # SRM is optional, hence call mount directly
+ msg ":: Mounting '${srm_dev}' to '/run/archiso/sfs/srm${srm_c}'"
+ if mount -o defaults,X-mount.mkdir -r "${srm_dev}" "/run/archiso/sfs/srm${srm_c}" ; then
+ if mount -o ro,X-mount.mkdir "${srm_dev}" "/run/archiso/sfs/srm${srm_c}" ; then
+ overlay_src_extra="${overlay_src_extra}:/run/archiso/sfs/srm${srm_c}"
+ echo ${srm_dev} >> /run/archiso/used_block_devices
+ srm_c=$(( srm_c + 1 ))