Spotter-VM/99-cleanup.sh

15 lines
268 B
Bash
Raw Normal View History

#!/bin/bash
# Remove git metadata
find / -name '.git*' -exec rm -rf {} \;
# Remove SSH settings
rm -rf /root/.ssh/
# Remove packages not necessary for release
apt-get -y purge git openssh-server
apt-get -y --purge autoremove
# Clean package cache
apt-get -y clean