Merge "Prestage container images at /opt/platform-backup"
This commit is contained in:
commit
2ae23916a8
@ -2787,14 +2787,28 @@ if [ "${controller}" = true ] ; then
|
||||
|
||||
ilog "Temporary backup mount is ${backup_mount}"
|
||||
mkdir -p "${backup_mount}"
|
||||
mount "${backup_device}" "${backup_mount}" 2>/dev/null
|
||||
mount "${backup_device}" "${backup_mount}"
|
||||
rc=$?
|
||||
if [ ${rc} -ne 0 ]; then
|
||||
report_failure_with_msg "Unable to mount ${backup_device} on ${backup_mount} [rc=${rc}]"
|
||||
fi
|
||||
|
||||
ilog "Copying repo to ${backup_mount}"
|
||||
cp -a ${repo} ${backup_mount}
|
||||
rc=$?
|
||||
if [ ${rc} -ne 0 ]; then
|
||||
report_failure_with_msg "Unable to copy repo to /opt/platform-backup"
|
||||
report_failure_with_msg "Unable to copy repo to /opt/platform-backup [rc=${rc}]"
|
||||
fi
|
||||
|
||||
if [ -e "/instboot/opt/platform-backup/${sw_release}" ]; then
|
||||
ilog "Copying images and patches to ${backup_mount}"
|
||||
cp -a /instboot/opt/platform-backup/${sw_release} ${backup_mount}
|
||||
rc=$?
|
||||
if [ ${rc} -ne 0 ]; then
|
||||
report_failure_with_msg "Unable to copy images from /instboot to /opt/platform-backup [rc=${rc}]"
|
||||
fi
|
||||
fi
|
||||
|
||||
umount "${backup_mount}"
|
||||
fi
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user