diff options
author | maanyagoenka <maanyagoenka@microsoft.com> | 2023-02-24 01:37:52 +0100 |
---|---|---|
committer | maanyagoenka <maanyagoenka@microsoft.com> | 2023-04-05 23:50:04 +0200 |
commit | b60e0f577740af89516f7c74967d7182637f27af (patch) | |
tree | a384a6b2ab9435acc7feb1958948995b9238b2e3 /src/shared/dissect-image.c | |
parent | Merge pull request #27154 from DaanDeMeyer/kconfig (diff) | |
download | systemd-b60e0f577740af89516f7c74967d7182637f27af.tar.xz systemd-b60e0f577740af89516f7c74967d7182637f27af.zip |
os-util: add a new confext image type and the ability to parse their release files
Adds a new image type called IMAGE_CONFEXT which is similar to IMAGE_SYSEXT but works
for the /etc/ directory instead of /usr/ and /opt/. This commit also adds the ability to
parse the release file that is present with the confext image in /etc/confext-release.d/
directory.
Diffstat (limited to 'src/shared/dissect-image.c')
-rw-r--r-- | src/shared/dissect-image.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/shared/dissect-image.c b/src/shared/dissect-image.c index 6000af0ce0..03dcd45e35 100644 --- a/src/shared/dissect-image.c +++ b/src/shared/dissect-image.c @@ -1791,7 +1791,7 @@ int dissected_image_mount( if (r < 0) return r; if (r == 0) { - r = path_is_extension_tree(where, m->image_name, FLAGS_SET(flags, DISSECT_IMAGE_RELAX_SYSEXT_CHECK)); + r = path_is_extension_tree(IMAGE_SYSEXT, where, m->image_name, FLAGS_SET(flags, DISSECT_IMAGE_RELAX_SYSEXT_CHECK)); if (r < 0) return r; if (r > 0) @@ -3054,7 +3054,7 @@ int dissected_image_acquire_metadata(DissectedImage *m, DissectImageFlags extra_ * we allow a fallback that matches on the first extension-release * file found in the directory, if one named after the image cannot * be found first. */ - r = open_extension_release(t, m->image_name, /* relax_extension_release_check= */ false, NULL, &fd); + r = open_extension_release(t, IMAGE_SYSEXT, m->image_name, /* relax_extension_release_check= */ false, NULL, &fd); if (r < 0) fd = r; /* Propagate the error. */ break; @@ -3606,7 +3606,7 @@ int verity_dissect_and_mount( assert(!isempty(required_host_os_release_id)); - r = load_extension_release_pairs(dest, dissected_image->image_name, relax_extension_release_check, &extension_release); + r = load_extension_release_pairs(dest, IMAGE_SYSEXT, dissected_image->image_name, relax_extension_release_check, &extension_release); if (r < 0) return log_debug_errno(r, "Failed to parse image %s extension-release metadata: %m", dissected_image->image_name); |