sysext: introduce ARCHITECTURE field to match host architecture
When an extension image has binaries they should match the host architecture. Currently there is no way to specify this requirement. Introduce an ARCHITECTURE field in the extension's release file that may be set to prevent loading on the wrong host architecture. Since this new field is introduced late, we don't want to make specifying it mandatory as it would break existing sysext images. See https://github.com/systemd/systemd/issues/24061
This commit is contained in:
+2
-1
@@ -715,7 +715,8 @@ EOF
|
||||
|
||||
export initdir="$TESTDIR/app-nodistro"
|
||||
mkdir -p "$initdir/usr/lib/extension-release.d" "$initdir/usr/lib/systemd/system"
|
||||
( echo "ID=_any" ) >"$initdir/usr/lib/extension-release.d/extension-release.app-nodistro"
|
||||
( echo "ID=_any"
|
||||
echo "ARCHITECTURE=_any" ) >"$initdir/usr/lib/extension-release.d/extension-release.app-nodistro"
|
||||
echo MARKER=1 >"$initdir/usr/lib/systemd/system/some_file"
|
||||
mksquashfs "$initdir" "$oldinitdir/usr/share/app-nodistro.raw" -noappend
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user