Create /var/log with systemd-tmpfiles

*systemd-tmpfiles* can create btrfs subvolumes with the `v` entry type.
Using this mechanism instead of the `init-storage` script will allow for
greater flexibility when adding other subvolumes later.

Unfortunately, the default configuration for *systemd-tmpfiles* already
includes an entry for `/var/log` with the `d` (directory) type.  Since
individual entries cannot be overridden, we need to modify this entry.
This commit is contained in:
2023-03-12 10:27:13 -05:00
parent 328b59e84a
commit 9d507c74ae
2 changed files with 1 additions and 2 deletions

View File

@@ -27,7 +27,6 @@ format_dev() {
mount "${dev}" "${tmpdir}" || exit
btrfs subvolume create "${tmpdir}"/var || exit
btrfs subvolume create "${tmpdir}"/var/log || exit
umount "${dev}" || exit
}