flokli / nix-casync

A more efficient way to store and substitute Nix store paths
80 stars 4 forks source link

parse .nar files on upload #41

Closed flokli closed 1 year ago

flokli commented 2 years ago

This can be beneficial for all sorts of things:

If we do this and discard the initial .nar file, we need to be able to synthesize the original .nar file back, bit-by-bit.

blaggacao commented 1 year ago

Another one:

flokli commented 1 year ago

As blogged, I proposed a new store protocol, that has all metadata separated from the file contents, and provides chunking metadata. It's slowly making its way into Tvix.

I don't intend to pursue this idea here any further.

There will be a HTTP Binary Cache frontend for any tvix-store (called nar-bridge) at some point, so regular Nix substitutors can still talk to it, but to take advantage of most of the new protocol benefits you need to talk the protocol ;-)