remove any existing RPM DB and recreate it at your initial boot

This commit is contained in:
Pratham Patel 2023-07-29 19:30:48 +05:30
parent 59570b9d98
commit b2609a3926
No known key found for this signature in database
1 changed files with 3 additions and 3 deletions

View File

@ -11,9 +11,6 @@ curl 'https://git.resf.org/thefossguy/rocky-linux-generic-images/raw/branch/r9/s
[ -f /usr/local/bin/expand-rootfs.sh ] && \
chmod --verbose +x /usr/local/bin/expand-rootfs.sh
# Rebuild the RPM database
rpm --rebuilddb
# Remove 'ifcfg-link' on generated images
rm -v -f /etc/sysconfig/network-scripts/ifcfg-link
@ -27,4 +24,7 @@ touch /etc/machine-id
# Like 'machine-id', the 'random-seed' must be generated by the machine on its own
rm -v -f /var/lib/systemd/random-seed
# Remove the RPM database, let it be re-created when the image boots for the first time
rm -v -f /var/lib/rpm/__db*
%end