DBCDK / morph

NixOS deployment tool
MIT License
839 stars 63 forks source link

Don't require using a file to pass nodes to build a derivation with all the system in a grid. #186

Open tomprince opened 2 years ago

tomprince commented 2 years ago

Based on #166.

This adds a new argument to machine, which is the list of node names to build. This also changes argsFile to argsJSON, for passing the list of node names from go to nix without needing to write a file to disk.

I also added the ability to pass a grid as an attrset, rather than a path to a file with the grid. (I was intending to use this to pass a pre-evaluated nixpkgs in to multiple grids in a single evaluation, to save evaluation time, but it appears that doing so doesn't appear to have a significant impact on evaluation time.

srhb commented 2 years ago

Deferring review here until prior PRs have been rebased and merged, sorry for the wait :)