Open asharrem opened 1 year ago
The trap as I defined is rather crude, as any error will perform chroot_exit_teardown()
,
Creates a potential loop if chroot_enter_setup()
has not completed.
A flag variable could conditionally perform chroot_exit_teardown()
- or conditionally the trap itself.
It would be nice to get this fixed, thanks for the tips @asharrem . What I've done in the past is just move the whole chroot to /tmp
upon dev iterations but it would be nice to have a better way.
During
chroot_build.sh
, any errors - perhaps due to missing packages (lupin-casper - 22.04) - will exit beforechroot_exit_teardown()
can cleanup. This leaves the build system in a dis-functional state - in the case of building locally. Addingtrap chroot_exit_teardown ERR
tobuild.sh
is a way of exitingchroot_build.sh
cleanly.removing the chroot during 'debootstap()' - before 'debootstap' - also cleans the
build.sh
workspace in case of EXIT on errors.