-
-
Notifications
You must be signed in to change notification settings - Fork 362
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Flake support #1202
[WIP] Flake support #1202
Conversation
Example usage: $ nixops create -d hydra-ec2-demo --flake github:edolstra/hydra-ec2-demo $ nixops deploy to get an EC2 instance running Hydra. Evaluation currently doesn't use pure mode because we need access to NixOps's NixOS modules, and to physical.nix.
Hello! Thank you for this PR. In the past several months, some major changes have taken place in
This is all accumulating in to what I hope will be a NixOps 2.0 My hope is that by adding types and more thorough automated testing, However, because of the major changes, it has become likely that this If you would like to see this merge, please bring it up to date with Thank you again for the work you've done here, I am sorry to be Graham |
Flake input changes: * Updated 'nixpkgs': 'github:edolstra/nixpkgs/44603b4103dbce2c9c18e6cc0df51a74f5eb8975' -> 'github:edolstra/nixpkgs/54a27fb2fc5fbd8927f9f6dc77fe1de1faa05266'
Flake input changes: * Updated 'nixops-aws': 'github:NixOS/nixops-aws/0da38bb5de82d7a118ac32ebefa7a2d5869ba5ab' -> 'github:NixOS/nixops-aws/af97c16f179cd0df94a6fc3ef470092122253f60' * Updated 'nixops-hetzner': 'github:NixOS/nixops-hetzner/33256100466e9624af21312d2ae0da8b0b80354a' -> 'github:NixOS/nixops-hetzner/663b02618ece7a92a72da408a552528ee8dd354c'
This can cause the package to depend on two different versions of Nixpkgs, leading to Python module clashes.
Superseded by #1365 which is based on latest master. |
This PR adds flake support to NixOps, meaning that you can do things like
This will create an EC2 instance running Hydra, using exactly the configuration locked by
flake.lock
.Currently evaluation is not as hermetic as we'd like since the NixOps-specific NixOS modules are provided impurely. Ideally, the flake would lock a particular version of the NixOps flake as input.
Likewise, NixOps needs to pass in the generated file
physical.nix
as an impure input. This is something of an inherent issue with the NixOps model. Maybe for flakes in local Git repositories,physical.nix
could be auto-committed.This PR also converts
release.nix
etc. toflake.nix
.update-all
(the script for fetching NixOps plugins) is no longer needed sincenix flake update
can do the same.