Commit 6c0c27db authored by jswaelens's avatar jswaelens

Merge branch '5736-add-new-variables-in-fai-integration-script' into '1.3-dev'

Resolve "Add new variables in FAI integration script"

Closes #5736

See merge request argonaut/argonaut!99
parents 18a4a7c0 d8612acc
......@@ -123,9 +123,13 @@ fi
# Actions for TFTPROOT_EFI32 if declared
if [ -n "$TFTPROOT_EFI32" ]; then
# WARNING about linking pxelinux.cfg
msg "WARNING: not forget to link pxelinux.cfg in $TFTPROOT_EFI32"
msg "WARNING: for exemple"
msg "WARNING: cd $TFTPROOT_EFI32 ; ln -s ../bios/pxelinux.cfg $TFTPROOT_EFI32/pxelinux.cfg"
# Copy as default kernel (TFTPROOT_EFI32)
if [ -f "$TFTPROOT_EFI32"/vmlinuz-"$version" ]; then
msg "installing vmlinuz-install"
if [ -f "$TFTPROOT"/vmlinuz-"$version" ]; then
msg "installing vmlinuz-install in $TFTPROOT_EFI32"
# Change vmlinuz-install name if declared
if [ -n "$DISTRELEASE" ]; then
......@@ -134,14 +138,15 @@ if [ -n "$TFTPROOT_EFI32" ]; then
vmlinuxName=vmlinuz-install
fi
cp -f "$TFTPROOT_EFI32"/vmlinuz-"$version" "$TFTPROOT_EFI32"/"$vmlinuxName"
cp -f "$TFTPROOT"/vmlinuz-"$version" "$TFTPROOT_EFI32"/vmlinuz-"$version"
cp -f "$TFTPROOT"/vmlinuz-"$version" "$TFTPROOT_EFI32"/"$vmlinuxName"
else
msg "ERROR: cannot find kernel to use as vmlinuz-install!!!"
fi
# Copy initrd if present (TFTPROOT_EFI32)
if [ -f "$TFTPROOT_EFI32"/initrd.img-"$version" ]; then
msg "installing initrd.img-install"
if [ -f "$TFTPROOT"/initrd.img-"$version" ]; then
msg "installing initrd.img-install in $TFTPROOT_EFI32"
# Change initrd.img-install name if declared
if [ -n "$DISTRELEASE" ]; then
......@@ -150,7 +155,8 @@ if [ -n "$TFTPROOT_EFI32" ]; then
initrdName=initrd.img-install
fi
cp -f "$TFTPROOT_EFI32"/initrd.img-"$version" "$TFTPROOT_EFI32"/"$initrdName"
cp -f "$TFTPROOT"/initrd.img-"$version" "$TFTPROOT_EFI32"/initrd.img-"$version"
cp -f "$TFTPROOT"/initrd.img-"$version" "$TFTPROOT_EFI32"/"$initrdName"
else
msg "ERROR: cannot find initrd image to use as initrd.img-xx !!!"
fi
......@@ -158,9 +164,13 @@ fi
# Actions for TFTPROOT_EFI64 if declared
if [ -n "$TFTPROOT_EFI64" ]; then
# WARNING about linking pxelinux.cfg
msg "WARNING: not forget to link pxelinux.cfg in $TFTPROOT_EFI64"
msg "WARNING: for exemple"
msg "WARNING: cd $TFTPROOT_EFI64 ; ln -s ../bios/pxelinux.cfg $TFTPROOT_EFI64/pxelinux.cfg"
# Copy as default kernel (TFTPROOT_EFI64)
if [ -f "$TFTPROOT_EFI64"/vmlinuz-"$version" ]; then
msg "installing vmlinuz-install"
if [ -f "$TFTPROOT"/vmlinuz-"$version" ]; then
msg "installing vmlinuz-install in $TFTPROOT_EFI64"
# Change vmlinuz-install name if declared
if [ -n "$DISTRELEASE" ]; then
......@@ -169,14 +179,15 @@ if [ -n "$TFTPROOT_EFI64" ]; then
vmlinuxName=vmlinuz-install
fi
cp -f "$TFTPROOT_EFI64"/vmlinuz-"$version" "$TFTPROOT_EFI64"/"$vmlinuxName"
cp -f "$TFTPROOT"/vmlinuz-"$version" "$TFTPROOT_EFI64"/vmlinuz-"$version"
cp -f "$TFTPROOT"/vmlinuz-"$version" "$TFTPROOT_EFI64"/"$vmlinuxName"
else
msg "ERROR: cannot find kernel to use as vmlinuz-install!!!"
fi
# Copy initrd if present (TFTPROOT_EFI64)
if [ -f "$TFTPROOT_EFI64"/initrd.img-"$version" ]; then
msg "installing initrd.img-install"
if [ -f "$TFTPROOT"/initrd.img-"$version" ]; then
msg "installing initrd.img-install in $TFTPROOT_EFI64"
# Change initrd.img-install name if declared
if [ -n "$DISTRELEASE" ]; then
......@@ -185,7 +196,8 @@ if [ -n "$TFTPROOT_EFI64" ]; then
initrdName=initrd.img-install
fi
cp -f "$TFTPROOT_EFI64"/initrd.img-"$version" "$TFTPROOT_EFI64"/"$initrdName"
cp -f "$TFTPROOT"/initrd.img-"$version" "$TFTPROOT_EFI64"/initrd.img-"$version"
cp -f "$TFTPROOT"/initrd.img-"$version" "$TFTPROOT_EFI64"/"$initrdName"
else
msg "ERROR: cannot find initrd image to use as initrd.img-xx !!!"
fi
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment