Open
Description
Right now, the filesystem type's format
argument supports arbitrary strings.
This can cause confusion when you expect to be able to insert zfs
, for example, and expect it to just work, see #820.
One solution, suggested in #820 (comment), would be to check for known bad values like zfs
, and return an error. This could be implemented with NixOS module assertions as we're relying on evalModules already.
Another option would be to change the type to only allow filesystems that can be built with an mkfs.<type>
command. From what I can tell, this is the entire list of currently supported file systems:
- bfs
- cramfs
- minix
- xfs
- btrfs
- vfat
- ext2
- ext3
- ext4
- bcachefs
- f2fs
Both options have their merits. Any opinions?