Commit graph

7 commits

Author SHA1 Message Date
Will Fancher
f8ed5f30c0 nixos/filesystems: Remove default = "auto" from fsType
NixOS has traditionally enabled the `ext` family of file systems by
default. Originally, when switching to systemd initrd, we wanted to
transition to making this explicit so that initrds could be made
without `ext`. The problem is that anyone with `fsType = "auto";` for
an `ext` file system in initrd will fail to boot, which is not really
an acceptable regression as we switch to systemd initrd by default.

By removing `default = "auto"` from `fsType`, we rule out the vast
majority of these regressions as eval errors, since most users of
`fsType = "auto"` for ext file systems are using it because of the
default value.

In hindsight, this is probably what #225352 was really about.
2026-04-05 19:06:28 -04:00
Philip Taron
cfaddae84d
nixosTests: fix writeText warning when userData is null
makeEc2Test's userData parameter is required but image-contents.nix
passes null, triggering a deprecation warning from writeText. Make
userData optional (defaulting to null) and create an empty user-data
file when it's not provided.
2026-03-24 18:40:48 -07:00
Tristan Ross
816b6de307
nixosTests: fix pure eval by setting system to null 2025-05-04 22:34:56 -07:00
Tristan Ross
727fafa66f
nixosTests: pass thru pkgs when available 2025-04-25 11:39:19 -07:00
Silvan Mosberger
4f0dadbf38 treewide: format all inactive Nix files
After final improvements to the official formatter implementation,
this commit now performs the first treewide reformat of Nix files using it.
This is part of the implementation of RFC 166.

Only "inactive" files are reformatted, meaning only files that
aren't being touched by any PR with activity in the past 2 months.
This is to avoid conflicts for PRs that might soon be merged.
Later we can do a full treewide reformat to get the rest,
which should not cause as many conflicts.

A CI check has already been running for some time to ensure that new and
already-formatted files are formatted, so the files being reformatted here
should also stay formatted.

This commit was automatically created and can be verified using

    nix-build https://github.com/infinisil/treewide-nixpkgs-reformat-script/archive/a08b3a4d199c6124ac5b36a889d9099b4383463f.tar.gz \
      --argstr baseRev b32a094368
    result/bin/apply-formatting $NIXPKGS_PATH
2024-12-10 20:26:33 +01:00
Leon Barrett
15c760d6b8 nixos/make-disk-image: fix contents dir paths
`make-disk-image` is a tool for creating VM images. It takes an argument
`contents` that allows one to specify files and directories that should
be copied into the VM image. However, directories end up not at the
specified target, but instead at a subdirectory of the target, with a
nix-store-like path, e.g.
`/target/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-source`. See issue
https://github.com/NixOS/nixpkgs/issues/226203 .

This change adds a test for make-disk-image's contents directory
handling and adds a fix (appending `/` to rsync input directory names).

This closes issue https://github.com/NixOS/nixpkgs/issues/226203 .
2023-04-16 09:54:45 -07:00
Francesco Gazzetta
8e52193721 nixosTests.image-contents: init 2020-12-20 21:24:50 +01:00