You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I encountered a situation where it would be beneficial to have an option in nix flake check to ignore certain outputs that are expected to fail when evaluated. Initially, I considered whether this should be an issue or a pull request, but I decided to proceed with the PR since this change introduces a potential solution.
The main use case for this flag is with NixOS configurations that are impure by design, such as configurations that include decryption keys or other sensitive information. For example, in my setup, I have the following outputs:
The -install configurations are used for deploying NixOS on new hosts with nixos-anywhere. These configurations contain sensitive keys for decrypting secrets needed only during installation, and they cause CI checks to fail since the secrets are not available on the CI machine. Currently, my CI setup runs nix fmt check on all outputs, but because of these impure -install configurations, it fails.
I thought that this was only usefull on a nixosConfiguration system (because why would you like to have an impure devShell, or package build?).
Describe the solution you'd like
A flag that disables checks for given outputs (maybe only nixosConfiguration systems, as the others makes sense to keep them pure).
Describe alternatives you've considered
Checking only the hosts that I know that they don't fail via CI, but it is easier to have a "blocklist" and ignore this outputs than a "whitelist" on a CI (because you can forgive to check new outputs, but you can't ignore an error in CI)
Is your feature request related to a problem? Please describe.
I encountered a situation where it would be beneficial to have an option in nix flake check to ignore certain outputs that are expected to fail when evaluated. Initially, I considered whether this should be an issue or a pull request, but I decided to proceed with the PR since this change introduces a potential solution.
The main use case for this flag is with NixOS configurations that are impure by design, such as configurations that include decryption keys or other sensitive information. For example, in my setup, I have the following outputs:
The -install configurations are used for deploying NixOS on new hosts with nixos-anywhere. These configurations contain sensitive keys for decrypting secrets needed only during installation, and they cause CI checks to fail since the secrets are not available on the CI machine. Currently, my CI setup runs nix fmt check on all outputs, but because of these impure -install configurations, it fails.
I thought that this was only usefull on a nixosConfiguration system (because why would you like to have an impure devShell, or package build?).
Describe the solution you'd like
A flag that disables checks for given outputs (maybe only nixosConfiguration systems, as the others makes sense to keep them pure).
I did a POC here: Pablito2020@6fb6f18
Describe alternatives you've considered
Checking only the hosts that I know that they don't fail via CI, but it is easier to have a "blocklist" and ignore this outputs than a "whitelist" on a CI (because you can forgive to check new outputs, but you can't ignore an error in CI)
Additional context
None
Priorities
Add 👍 to issues you find important.
The text was updated successfully, but these errors were encountered: