This repository has been archived on 2024-04-07. You can view files and clone it, but cannot push or open issues or pull requests.
dotfiles/root/fstab

40 lines
1.1 KiB
Plaintext
Raw Normal View History

2021-10-29 05:19:46 +02:00
{{@@ non_templated(_dotfile_abs_dst) @@}}
2021-06-23 06:49:38 +02:00
##### Dotdrop-start #####
2022-02-12 03:01:19 +01:00
# <filesystem> <dir> <type> <options> <dump> <pass>
2021-06-23 16:59:23 +02:00
2022-04-13 03:44:26 +02:00
{%@@ set btrfs_opt_t = "defaults,autodefrag,rw,noatime,compress=zstd:3,subvol={}" @@%}
2021-06-23 16:59:23 +02:00
{%@@ set entry_t = "UUID={uuid} {path} {fs} {opts} {dump} {pass}" @@%}
2022-02-12 03:01:19 +01:00
{%@@ for partition in filesystem.partition @@%}
{{@@ entry_t.format(
uuid= partition.uuid ,
path= partition.path ,
fs= partition.type,
opts= partition.options,
dump= "0",
pass= "0",
) @@}}
{%@@ endfor @@%}
2021-06-23 06:49:38 +02:00
2022-02-12 03:01:19 +01:00
{%@@ set new_partitions = filesystem.btrfs_subvolumes.update({root_subvol: '/'}) @@%}
{%@@ for name, path in filesystem.btrfs_subvolumes.items() @@%}
2021-06-23 16:59:23 +02:00
{{@@ entry_t.format(
2022-02-12 03:01:19 +01:00
uuid= root_uuid ,
2021-06-23 16:59:23 +02:00
path= path ,
fs= "btrfs",
opts= btrfs_opt_t.format(name),
dump= "0",
pass= ("root" in name) | int,
) @@}}
2021-06-23 06:49:38 +02:00
{%@@ endfor @@%}
/swap/swapfile none swap defaults 0 0
2021-09-04 02:14:35 +02:00
tmpfs /tmp tmpfs rw,nodev,nosuid,size=2G 0 0
2021-06-23 06:49:38 +02:00
{%@@ if zram @@%}
2021-06-30 00:10:21 +02:00
/dev/zram0 none swap defaults,pri=100 0 0
2021-06-23 06:49:38 +02:00
{%@@ endif @@%}
# vim: ft=etc-fstab