sysext: Add --mutable mode flag
authorKrzesimir Nowak <knowak@microsoft.com>
Thu, 15 Feb 2024 14:16:08 +0000 (15:16 +0100)
committerKrzesimir Nowak <knowak@microsoft.com>
Thu, 22 Feb 2024 18:06:22 +0000 (19:06 +0100)
commit58a28be5ac53af74fbd7bcc2e8adabb33d0d1b18
tree6a94523e5fec2f427cd3899cb8c8629694fe75c5
parent8a8990653ca21a313ad0cd460a52562cf7f267b5
sysext: Add --mutable mode flag

The flag takes "auto" or "import" or a boolean value.

"auto" causes systemd-sysext to make a decision about mutability of the merged
hierarchy based on existence of the upper directory in
`/var/lib/extensions.mutable/${hierarchy}`.

"import" causes the existing upper dir to be actually used as another lower
dir, which results in read-only merged hierarchy.

True value makes systemd-sysext to create the upper dir if it's missing and to
make the merged hierarchy mutable.

False value makes systemd-sysext to ignore upper dir completely, and create a
read-only merged hierarchy.

The default is false value.
src/sysext/sysext.c