Support global sysext/confext in systemd-stub/systemd-sysext (#38113)
Systemd-stub supports loading addons, credentials, system and configuration extensions from ESP and while addons and credentials can be both global and per-UKI, sysext/confext are only per-UKI. Add support for global sysext/confext to systemd-stub/systemd-sysext. Fixes #37993
This commit is contained in:
@@ -76,20 +76,22 @@ const char* const image_search_path[_IMAGE_CLASS_MAX] = {
|
||||
"/usr/lib/confexts\0",
|
||||
};
|
||||
|
||||
/* Inside the initrd, use a slightly different set of search path (i.e. include .extra/sysext/ and
|
||||
* .extra/confext/ in extension search dir) */
|
||||
/* Inside the initrd, use a slightly different set of search path (i.e. include .extra/sysext/,
|
||||
* /.extra/global_sysext, .extra/confext/, and /.extra/global_confext in extension search dir) */
|
||||
static const char* const image_search_path_initrd[_IMAGE_CLASS_MAX] = {
|
||||
/* (entries that aren't listed here will get the same search path as for the non initrd-case) */
|
||||
|
||||
[IMAGE_SYSEXT] = "/etc/extensions\0" /* only place symlinks here */
|
||||
"/run/extensions\0" /* and here too */
|
||||
"/var/lib/extensions\0" /* the main place for images */
|
||||
"/.extra/sysext\0", /* put sysext picked up by systemd-stub last, since not trusted */
|
||||
"/.extra/sysext\0" /* put sysext (per-UKI and global) picked up by systemd-stub */
|
||||
"/.extra/global_sysext\0", /* last, since not trusted */
|
||||
|
||||
[IMAGE_CONFEXT] = "/run/confexts\0" /* only place symlinks here */
|
||||
"/var/lib/confexts\0" /* the main place for images */
|
||||
"/usr/local/lib/confexts\0"
|
||||
"/.extra/confext\0", /* put confext picked up by systemd-stub last, since not trusted */
|
||||
"/.extra/confext\0" /* put confext (per-UKI and global) picked up by systemd-stub */
|
||||
"/.extra/global_confext\0", /* last, since not trusted. */
|
||||
};
|
||||
|
||||
static const char* image_class_suffix_table[_IMAGE_CLASS_MAX] = {
|
||||
|
||||
Reference in New Issue
Block a user