forked from mirrored-repos/manjaro-tools
buildiso: support chrootcfg module if netinstall is enabled #246
This commit is contained in:
parent
955313db3f
commit
077f4848e2
6 changed files with 35 additions and 5 deletions
|
@ -36,6 +36,8 @@ show_profile(){
|
|||
[[ ${target_arch} == 'x86_64' ]] && msg2 "multilib: %s" "${multilib}"
|
||||
|
||||
msg2 "cal_netinstall: %s" "${cal_netinstall}"
|
||||
msg2 "cal_unpackfs: %s" "${cal_unpackfs}"
|
||||
|
||||
msg2 "efi_boot_loader: %s" "${efi_boot_loader}"
|
||||
msg2 "efi_part_size: %s" "${efi_part_size}"
|
||||
|
||||
|
|
|
@ -38,7 +38,10 @@
|
|||
# efi_part_size=31M
|
||||
|
||||
# configure calamares for netinstall
|
||||
# cal_netinstall=false
|
||||
# cal_netinstall="false"
|
||||
|
||||
# configure calamares to use chrootcfg instead of unpackfs
|
||||
# cal_netunpackfs="true"
|
||||
|
||||
# unset defaults to given value
|
||||
# plymouth_theme=manjaro-elegant
|
||||
|
|
|
@ -140,6 +140,15 @@
|
|||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>cal_unpackfs=</varname></term>
|
||||
|
||||
<listitem><para>Accepts
|
||||
<option>true</option> (the default)
|
||||
<option>false</option>.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><varname>efi_boot_loader=</varname></term>
|
||||
|
||||
|
|
|
@ -109,9 +109,11 @@ write_calamares_unpack_conf(){
|
|||
echo " - source: \"/bootmnt/${iso_name}/${target_arch}/root-image.sqfs\"" >> "$conf"
|
||||
echo " sourcefs: \"squashfs\"" >> "$conf"
|
||||
echo " destination: \"\"" >> "$conf"
|
||||
echo " - source: \"/bootmnt/${iso_name}/${target_arch}/${profile}-image.sqfs\"" >> "$conf"
|
||||
echo " sourcefs: \"squashfs\"" >> "$conf"
|
||||
echo " destination: \"\"" >> "$conf"
|
||||
if [[ -f /bootmnt/${iso_name}/${target_arch}/${profile}-image.sqfs ]];then
|
||||
echo " - source: \"/bootmnt/${iso_name}/${target_arch}/${profile}-image.sqfs\"" >> "$conf"
|
||||
echo " sourcefs: \"squashfs\"" >> "$conf"
|
||||
echo " destination: \"\"" >> "$conf"
|
||||
fi
|
||||
}
|
||||
|
||||
write_calamares_users_conf(){
|
||||
|
@ -177,8 +179,12 @@ write_calamares_settings_conf(){
|
|||
echo "- exec:" >> "$conf"
|
||||
echo " - partition" >> "$conf"
|
||||
echo " - mount" >> "$conf"
|
||||
echo " - unpackfs" >> "$conf"
|
||||
if ${cal_netinstall};then
|
||||
if ${cal_unpackfs};then
|
||||
echo " - unpackfs" >> "$conf"
|
||||
else
|
||||
echo " - chrootcfg" >> "$conf"
|
||||
fi
|
||||
echo " - networkcfg" >> "$conf"
|
||||
echo " - packages" >> "$conf"
|
||||
fi
|
||||
|
|
|
@ -561,6 +561,10 @@ check_profile(){
|
|||
done
|
||||
|
||||
[[ -f "${profile_dir}/Packages-Mhwd" ]] && packages_mhwd=${profile_dir}/Packages-Mhwd
|
||||
|
||||
if ! ${cal_netinstall};then
|
||||
cal_unpackfs="true"
|
||||
fi
|
||||
}
|
||||
|
||||
check_requirements(){
|
||||
|
@ -672,6 +676,7 @@ reset_profile(){
|
|||
unset tracker_url
|
||||
unset piece_size
|
||||
unset cal_netinstall
|
||||
unset cal_unpackfs
|
||||
}
|
||||
|
||||
make_profile(){
|
||||
|
|
|
@ -376,6 +376,9 @@ check_profile_vars(){
|
|||
if ! is_valid_bool "${cal_netinstall}";then
|
||||
die "cal_netinstall only accepts true/false value!"
|
||||
fi
|
||||
if ! is_valid_bool "${cal_unpackfs}";then
|
||||
die "cal_unpackfs only accepts true/false value!"
|
||||
fi
|
||||
}
|
||||
|
||||
load_profile_config(){
|
||||
|
@ -444,6 +447,8 @@ load_profile_config(){
|
|||
|
||||
[[ -z ${cal_netinstall} ]] && cal_netinstall='false'
|
||||
|
||||
[[ -z ${cal_unpackfs} ]] && cal_netunpackfs='true'
|
||||
|
||||
check_profile_vars
|
||||
|
||||
return 0
|
||||
|
|
Loading…
Reference in a new issue