Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Feb 2025 21:16:41 GMT
From:      Colin Percival <cperciva@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 8984d070d666 - stable/13 - release: Chase location of pkg repo databases
Message-ID:  <202502092116.519LGfR1045886@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by cperciva:

URL: https://cgit.FreeBSD.org/src/commit/?id=8984d070d6669669754ba1f66c7acd6d7dca1d2a

commit 8984d070d6669669754ba1f66c7acd6d7dca1d2a
Author:     Colin Percival <cperciva@FreeBSD.org>
AuthorDate: 2025-02-04 00:10:47 +0000
Commit:     Colin Percival <cperciva@FreeBSD.org>
CommitDate: 2025-02-09 21:16:25 +0000

    release: Chase location of pkg repo databases
    
    pkg used to store copies of upstream repository databases in
    /var/db/pkg/repo-*.sqlite.  About a year ago this was moved to
    /var/db/pkg/repos/*/, resulting in FreeBSD cloud images no longer
    having those (unhelpful since they'll be long out of date before
    the cloud images are launched) databases removed.
    
    Remove the correct location, and hope that future pkg updates don't
    break the base system again.
    
    Sponsored by:   Amazon
    
    (cherry picked from commit 078e8b34b13d6d0663661542eeac9007806fccdc)
---
 release/tools/ec2.conf     | 2 +-
 release/tools/vagrant.conf | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/release/tools/ec2.conf b/release/tools/ec2.conf
index 86706e21513c..2776331d9905 100644
--- a/release/tools/ec2.conf
+++ b/release/tools/ec2.conf
@@ -45,7 +45,7 @@ vm_extra_pre_umount() {
 	chroot ${DESTDIR} ${EMULATOR} env ASSUME_ALWAYS_YES=yes \
 		/usr/sbin/pkg delete -f -y pkg
 	umount ${DESTDIR}/dev
-	rm ${DESTDIR}/var/db/pkg/repo-*.sqlite
+	rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD
 
 	# The size of the EC2 root disk can be configured at instance launch
 	# time; expand our filesystem to fill the disk.
diff --git a/release/tools/vagrant.conf b/release/tools/vagrant.conf
index 5a4aa7d3ba79..2735ad2974cb 100644
--- a/release/tools/vagrant.conf
+++ b/release/tools/vagrant.conf
@@ -20,7 +20,7 @@ vagrant_common () {
 	# them from the image allows it to boot faster.
 	env ASSUME_ALWAYS_YES=yes pkg -c ${DESTDIR} clean -y -a
 	env ASSUME_ALWAYS_YES=yes pkg -c ${DESTDIR} delete -f -y pkg
-	rm ${DESTDIR}/var/db/pkg/repo-*.sqlite
+	rm -r ${DESTDIR}/var/db/pkg/repos/FreeBSD
 
 	# Vagrant instances use DHCP to get their network configuration.
 	echo 'ifconfig_DEFAULT="SYNCDHCP"' >> ${DESTDIR}/etc/rc.conf



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202502092116.519LGfR1045886>