2
0
mirror of https://github.com/frappe/bench.git synced 2024-11-12 00:06:36 +00:00
bench/vm/scripts/debian_family/cleanup.sh

13 lines
290 B
Bash
Raw Normal View History

2018-03-05 07:46:34 +00:00
#!/bin/bash -eux
# Apt cleanup
apt-get autoremove
apt-get clean
apt-get update
# Zero out the rest of the free space using dd, then delete the written file.
dd if=/dev/zero of=/EMPTY bs=1M
rm -f /EMPTY
# Add `sync` so Packer doesn't quit too early, before the large file is deleted.
sync