core: Add RootEphemeral= setting
This setting allows services to run in an ephemeral copy of the root directory or root image. To make sure the ephemeral copies are always cleaned up, we add a tmpfiles snippet to unconditionally clean up /var/lib/systemd/ephemeral. To prevent in use ephemeral copies from being cleaned up by tmpfiles, we use the newly added COPY_LOCK_BSD and BTRFS_SNAPSHOT_LOCK_BSD flags to take a BSD lock on the ephemeral copies which instruct tmpfiles to not touch those ephemeral copies as long as the BSD lock is held.
This commit is contained in:
@@ -992,7 +992,8 @@ static int bus_append_execute_property(sd_bus_message *m, const char *field, con
|
||||
"LockPersonality",
|
||||
"ProtectHostname",
|
||||
"MemoryKSM",
|
||||
"RestrictSUIDSGID"))
|
||||
"RestrictSUIDSGID",
|
||||
"RootEphemeral"))
|
||||
return bus_append_parse_boolean(m, field, eq);
|
||||
|
||||
if (STR_IN_SET(field, "ReadWriteDirectories",
|
||||
|
||||
Reference in New Issue
Block a user