Allow creating ISO files for installing windows
This commit is contained in:
parent
e6ea44a216
commit
24e557e95c
1 changed files with 74 additions and 56 deletions
20
deploy.fish
20
deploy.fish
|
@ -12,6 +12,7 @@ begin
|
||||||
set -l setupLabel "winiso-valhalla"
|
set -l setupLabel "winiso-valhalla"
|
||||||
set -l buildDir "$(status dirname)/build"
|
set -l buildDir "$(status dirname)/build"
|
||||||
set -l cacheDir ~/.cache/winiso-valhalla
|
set -l cacheDir ~/.cache/winiso-valhalla
|
||||||
|
set -l isoFile "$buildDir/winiso-valhalla.iso"
|
||||||
set -l winpe "$cacheDir/winpe.iso"
|
set -l winpe "$cacheDir/winpe.iso"
|
||||||
set -l winPath "/media/win"
|
set -l winPath "/media/win"
|
||||||
set -l winpePath "/media/winpe"
|
set -l winpePath "/media/winpe"
|
||||||
|
@ -20,6 +21,8 @@ begin
|
||||||
set -l dataPath "/media/data"
|
set -l dataPath "/media/data"
|
||||||
set -l winpeOverlay (mktemp -d)
|
set -l winpeOverlay (mktemp -d)
|
||||||
set -l winOverlay (mktemp -d)
|
set -l winOverlay (mktemp -d)
|
||||||
|
set -l upperDir (mktemp -d)
|
||||||
|
set -l workDir (mktemp -d)
|
||||||
set -l editionField "Edition ID"
|
set -l editionField "Edition ID"
|
||||||
set -l wimFile "sources/install.wim"
|
set -l wimFile "sources/install.wim"
|
||||||
|
|
||||||
|
@ -113,8 +116,22 @@ begin
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
sudo mount --mkdir -t overlay overlay -o lowerdir="$winOverlay":"$winPath" "$valhallaPath"
|
sudo mount --mkdir -t overlay overlay -o lowerdir="$winOverlay":"$winpePath":"$winPath",upperdir="$upperDir",workdir="$workDir" "$valhallaPath"
|
||||||
|
|
||||||
|
if [ -z "$_flag_usb" ]
|
||||||
|
mkisofs \
|
||||||
|
-V "$setupLabel" \
|
||||||
|
-no-emul-boot \
|
||||||
|
-b "efi/microsoft/boot/efisys.bin" \
|
||||||
|
-iso-level 4 \
|
||||||
|
-udf \
|
||||||
|
-joliet \
|
||||||
|
-disable-deep-relocation \
|
||||||
|
-omit-version-number \
|
||||||
|
-relaxed-filenames \
|
||||||
|
-output "$isoFile" \
|
||||||
|
"$valhallaPath"
|
||||||
|
else
|
||||||
if [ ! -b "$WIN_DISK" ]
|
if [ ! -b "$WIN_DISK" ]
|
||||||
chooseDisk WIN_DISK
|
chooseDisk WIN_DISK
|
||||||
end
|
end
|
||||||
|
@ -176,4 +193,5 @@ begin
|
||||||
sudo rm -rf "$path"
|
sudo rm -rf "$path"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue