Create subvolumes in init-storage
It turns out that we cannot use `systemd-tmpfiles` to create our Btrfs subvolumes. Since the directories we are interested in, specifically `/var/log` and `/var/tmp` already exist in the rootfs image and are therefore copied into the mutable filesystem, `systemd-tmpfiles` ignores them. To avoid having to explicitly specify the SELinux context for each subvolume created on the persistent filesystem, `init-storage` now executes `setfiles` to set the appropriate labels.
This commit is contained in:
@@ -65,9 +65,10 @@ dontaudit aimee_storinit_t mount_runtime_t:dir write;
|
||||
|
||||
seutil_read_config(aimee_storinit_t)
|
||||
seutil_read_file_contexts(aimee_storinit_t)
|
||||
seutil_read_bin_policy(aimee_storinit_t)
|
||||
seutil_domtrans_setfiles(aimee_storinit_t)
|
||||
|
||||
kernel_rw_unlabeled_dirs(aimee_storinit_t)
|
||||
kernel_relabelfrom_unlabeled_dirs(aimee_storinit_t)
|
||||
kernel_manage_unlabeled_dirs(aimee_storinit_t)
|
||||
|
||||
auth_manage_shadow(aimee_storinit_t)
|
||||
auth_relabel_shadow(aimee_storinit_t)
|
||||
|
||||
Reference in New Issue
Block a user