From 0ecd10bf307049b9833e69f331ec049ae8840d85 Mon Sep 17 00:00:00 2001 From: Florian Klink Date: Sat, 19 Nov 2022 20:34:49 +0000 Subject: feat(tvix/nar-bridge): init MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This provides a Nix HTTP Binary Cache interface in front of a tvix-store that's reachable via gRPC. TODOs: - remove import command, move serve up to toplevel. We have nix-copy- closure and tvix-store commands. - loop into CI. We should be able to fetch the protos as a third-party dependency. - Check if we can test nar-bridge slightly easier in an integration test. - Ensure we support connecting to unix sockets and grpc+http at least, using the same syntax as tvix-store. - Don't buffer the entire blob when rendering NAR Co-Authored-By: Connor Brewster Co-Authored-By: Márton Boros Co-Authored-By: Vo Minh Thu Change-Id: I6064474e49dfe78cea67676957462d9f28658d4a Reviewed-on: https://cl.tvl.fyi/c/depot/+/9339 Tested-by: BuildkiteCI Reviewed-by: tazjin --- tvix/nar-bridge/go.mod | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 tvix/nar-bridge/go.mod (limited to 'tvix/nar-bridge/go.mod') diff --git a/tvix/nar-bridge/go.mod b/tvix/nar-bridge/go.mod new file mode 100644 index 0000000000..dc22e32147 --- /dev/null +++ b/tvix/nar-bridge/go.mod @@ -0,0 +1,35 @@ +module code.tvl.fyi/tvix/nar-bridge + +require ( + code.tvl.fyi/tvix/store/protos v0.0.0-20230909121302-7b7aa6704a9d + github.com/alecthomas/kong v0.7.1 + github.com/go-chi/chi v1.5.4 + github.com/go-chi/chi/v5 v5.0.7 + github.com/google/go-cmp v0.5.9 + github.com/nix-community/go-nix v0.0.0-20230825195510-c72199eca18e + github.com/sirupsen/logrus v1.9.0 + github.com/stretchr/testify v1.8.1 + google.golang.org/grpc v1.51.0 + google.golang.org/protobuf v1.28.1 + lukechampine.com/blake3 v1.1.7 +) + +require ( + github.com/davecgh/go-spew v1.1.1 // indirect + github.com/golang/protobuf v1.5.2 // indirect + github.com/klauspost/cpuid/v2 v2.0.9 // indirect + github.com/minio/sha256-simd v1.0.0 // indirect + github.com/mr-tron/base58 v1.2.0 // indirect + github.com/multiformats/go-multihash v0.2.1 // indirect + github.com/multiformats/go-varint v0.0.6 // indirect + github.com/pmezard/go-difflib v1.0.0 // indirect + github.com/spaolacci/murmur3 v1.1.0 // indirect + golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e // indirect + golang.org/x/net v0.7.0 // indirect + golang.org/x/sys v0.5.0 // indirect + golang.org/x/text v0.7.0 // indirect + google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect +) + +go 1.19 -- cgit 1.4.1