Warn against rm -rf'ing directory created by script
haileys opened this issue · comments
Hailey Somerville commented
alpine-chroot-install
mounts several filesystems into the created chroot directory - even before it's actually chrooted into.
It appears that the destroy
script takes care to unmount these filesystems before removing the chroot, however it is not immediately clear that the destroy
script is the only safe way to remove the chroot.
I have just hosed a running Linux system due to making this mistake. I believe only transient state has been affected and a reboot will fix things, but a warning about this pitfall would be very much appreciated.
Jonathan De Wachter commented
Same happened to me.