Fixing the previous dirty workaround...

This commit is contained in:
Alexandre Aubin 2018-04-07 22:53:07 +02:00
parent 4f0909c49b
commit 4e89b2ce33

View file

@ -21,12 +21,14 @@ echo "Cleaning ..."
on_chroot << EOF on_chroot << EOF
apt-get clean apt-get clean
find /var/log -type f -exec rm {} \; find /var/log -type f -exec rm {} \;
ps -ef --forest | grep qemu
EOF EOF
# Gotta manually kill those stuff which are some sort of daemon running # Gotta manually kill those stuff which are some sort of daemon running
# for slapd / nscd / nslcd ... otherwise the script is unable to unmount # for slapd / nscd / nslcd ... otherwise the script is unable to unmount
# the rootfs/image after that ? # the rootfs/image after that ?
for PID in `ps -ef --forest | awk '$8=="/usr/bin/qemu-arm-static" {print $2}'` for PID in `ps -ef --forest | grep "qemu-arm-static" | grep "nginx\|nscd\|slapd\|nslcd" | awk '{print $2}'`
do do
echo "Killing $PID"
kill -9 $PID kill -9 $PID
done done