from .. import print_section_start, print_section_end
from ..xlate import XLATOR
-__version__ = '0.2.5'
+__version__ = '0.2.6'
LOG = logging.getLogger(__name__)
print_section_start('post_install_tasks', 'Exec post install tasks ...', collapsed=True)
logfiles = (
+ '/var/log/audit/audit.log',
'/var/log/boot.log',
+ '/var/log/cloud-init.log',
+ '/var/log/cloud-init-output.log',
'/var/log/cron',
'/var/log/dnf*.log',
'/var/log/hawkey.log',
'/var/log/messages',
'/var/log/secure',
+ '/var/log/tuned/tuned.log'
'/var/log/wtmp',
'/var/log/vmware-*.log*',
'/var/log/yum*.log',
echo "Removing SSH host keys ..."
rm -v /etc/ssh/ssh_host_*
+ echo
+ echo "-----------------------------------------------------------"
+ echo "Cleaning lastlog ..."
+ lastlog --clear --user root
+
echo
echo "-----------------------------------------------------------"
echo "Clearing journal log ..."
echo
echo "-----------------------------------------------------------"
- echo "Truncating /var/log/*tmp ..."
+ echo "Truncating /var/log/*tmp and /var/log/messages ..."
cp -v /dev/null /var/log/btmp
cp -v /dev/null /var/log/wtmp
+ cp -v /dev/null /var/log/messages
echo
echo "Sleeping some seconds ..."