the `modules = []` section of each host. This gives us the flexibility to define
configurations that are exclusive to the host and can't trivially be made a
module such as `hostName`, `operatingSystem` (for conditional modules) and
`secrets` configuration.
the `modules = []` section of each host. There we define configurations that are
exclusive to the host and can't trivially be made a module such as `hostName`,
`operatingSystem` (for conditional modules) and `secrets` configuration.
I would like to move some of these variable configs to modules at some point and
group common modules to keep the hosts file cleaner.
## Other tools
### Secrets
All secrets are handled by (r)agenix and agenix-rekey.
(r)agenix: <https://github.com/ryantm/agenix>
agenix-rekey: <https://github.com/oddlama/agenix-rekey>
### Imports
Imports are handled by import-tree in `modules/outputs.nix`. It automatically
imports all nix files in the specified directory (`./modules` in my case).
import-tree: <https://github.com/vic/import-tree>
### Flake inputs
Flake inputs are automatically managed by flake-file which allows me to
use/define inputs closer to where they are used. For example,
`modules/editor.nix` contains `flake-file.inputs.helix`. By running
`nix run .#write-flake` the `flake.nix` file is automatically updated by
flake-file.
I also use nix-auto-follow to improve evaluation (and possibly build) times by
checking for duplicate dependencies in our `flake.lock` and suggesting ways to
improve it.
flake-file: <https://github.com/vic/flake-file>
nix-auto-follow: <https://github.com/fzakaria/nix-auto-follow>