]> git.ipfire.org Git - thirdparty/mkosi.git/commit
installer: Make sure package manager state is preserved in the image 3682/head
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Thu, 10 Apr 2025 20:29:44 +0000 (22:29 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 16 Apr 2025 09:01:55 +0000 (11:01 +0200)
commit96e512fe6e93846868ff2f8b946b8bbcc4b5fb54
tree4665916b854cc3d99ae708c47d7adb2bc8c7b5d1
parentb859a7cf0a9797592f4699c7f60189dc4d620f93
installer: Make sure package manager state is preserved in the image

Package manager state should be preserved in the image as various
local features of the package manager may depend on this data to be
available. For pacman and zypper we already store local state inside
the image. For apt, we achieve this by storing all state in the image
by default except lists which is the repository metadata which we still
don't include in the image. For dnf/dnf5, we make sure the persistdir
points to inside the image.

Note that this state is still subject to removal by CleanPackageMetadata=
if the package manager is not installed or the option is explicitly enabled.

Fixes #3659
mkosi/__init__.py
mkosi/installer/apt.py
mkosi/installer/dnf.py