HomeFreeBSD

vmimage.subr: Log pkg/local.sqlite if pkgbase

Description

vmimage.subr: Log pkg/local.sqlite if pkgbase

We were doing this in vm_extra_install_packages but VM images without
any extra packages installed would not get this installed. This
results in a pkgbase system which thinks it doesn't have any packages
installed (even though all the files are right there).

Add a "metalog_add_data ./var/db/pkg/local.sqlite" call to the pkgbase
install code path, and make the call from vm_extra_install_packages
conditional on !PKGBASE.

Approved by: re (cperciva)
Reported by: Michael Dexter
MFC after: immediately (needed for 15.0-RC1)

(cherry picked from commit 10a4f2d016dccb5cfa03800bebc09a9b421c4df7)
(cherry picked from commit 6b15dc234dc56cd65f07063c1f933c214c477120)

Details

Provenance
cpercivaAuthored on Sat, Nov 15, 9:29 PM
Parents
rG567ba10572cf: GCE: Don't .error on unsupported targets
Branches
Unknown
Tags
Unknown