Skip to content
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

Use Nix copy command instead of nix-closure-copy #76

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

smulikHakipod
Copy link

@smulikHakipod smulikHakipod commented Jul 18, 2023

This relates to #63
I tested it, and its very fast.
It only work fast on NisOS unstable though, as NixOS 23.05 contains Nix 2.13 which doesn't support that yet.
On older nixos it just works slowly.

@exarkun
Copy link
Contributor

exarkun commented Jul 18, 2023

I tested it, and its very fast.

Can you provide some numbers to go with this? How does it deal with latency?

@smulikHakipod
Copy link
Author

smulikHakipod commented Jul 18, 2023

@exarkun sure,
here is a time terraform apply -auto-approve on some example terraform on AWS (with around 100ms latency) and sample nix config without the patch:

terraform apply -auto-approve 14.52s user 4.95s system 3% cpu 8:26.58 total

and here is with the patch (on completely new machine):

terraform apply -auto-approve 7.47s user 1.55s system 14% cpu 1:00.89 total

More than 8x improvment.

@exarkun
Copy link
Contributor

exarkun commented Jun 6, 2024

Now that this project is maintained by nix-community, maybe this PR can be merged? :) Or at least reviewed by a maintainer and whatever changes are necessary requested.

I was away from deploy_nixos for a while but, if this project is maintained, there's a good chance I'll start using it again in a new project.

@adrian-gierakowski
Copy link
Contributor

@exarkun i don’t have capacity to test this right now. I’d be happy to merge it if it was opt-in. Can we add a flag in the terraform module to switch between original implementation and this one? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants