chore: create /.update state file

This commit is contained in:
Rudra Saraswat 2024-02-09 22:34:44 +05:30
parent 684b1b59d3
commit 08ffe04565
2 changed files with 3 additions and 1 deletions

View file

@ -393,6 +393,8 @@ Server = {package_repo["repo-url"]}
exec('grub-mkconfig', '-o', '/boot/grub/grub.cfg') exec('grub-mkconfig', '-o', '/boot/grub/grub.cfg')
exec('touch', '/.update')
info('downloaded update and generated new rootfs') info('downloaded update and generated new rootfs')
info('you may reboot now') info('you may reboot now')

View file

@ -4,7 +4,7 @@ run_latehook() {
echo echo
# Remove /new_root/.successful-update if exists # Remove /new_root/.successful-update if exists
rm -f /new_root/.successful-update rm -f /new_root/.successful-update /.update
# Detect if update downloaded. # Detect if update downloaded.
if [[ -d /new_root/.update_rootfs ]]; then if [[ -d /new_root/.update_rootfs ]]; then