Upgrade debs + cleaning logs
This commit is contained in:
parent
bc7d76b966
commit
33fb7055cc
|
@ -36,6 +36,11 @@ debootstrap() {
|
|||
"$SCRIPT"
|
||||
}
|
||||
|
||||
upgrade_debs() {
|
||||
secondstage apt-get update
|
||||
secondstage apt-get upgrade
|
||||
}
|
||||
|
||||
secondstage() {
|
||||
# This step could be done directly by removing
|
||||
sudo chroot "$TARGET" /debootstrap/debootstrap --second-stage
|
||||
|
@ -51,12 +56,15 @@ patch_target() {
|
|||
|
||||
clean_target() {
|
||||
clean_paths=$1
|
||||
echo apt-get clean | do_in_target
|
||||
do_in_target apt-get clean
|
||||
for path in $clean_paths; do
|
||||
if [ -e "$TARGET/$path" ]; then
|
||||
sudo rm -rf "$TARGET/$path"
|
||||
fi
|
||||
done
|
||||
for file in $(find "$TARGET/var/log" -type f); do
|
||||
echo | tee $file
|
||||
done
|
||||
}
|
||||
|
||||
archive_target() {
|
||||
|
|
Loading…
Reference in New Issue