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
ipfs-cluster: init at v0.5.0 #45818
ipfs-cluster: init at v0.5.0 #45818
Conversation
# fetchgx stores packages by their ipfs hash | ||
# this will rewrite github.com/ imports to gx/ipfs/ | ||
cd go/src/${goPackagePath} | ||
${gx-go}/bin/gx-go rewrite |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This reference is incorrect when cross-building because we need gx-go
to run during build.
Instead, please add nativeBuildInputs = [ gx-go ];
above and just write gx-go
here (no absolute path).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@GrahamcOfBorg build ipfs-cluster |
Failure on aarch64-linux (full log) Attempted: ipfs-cluster Partial log (click to expand)
|
Success on x86_64-linux (full log) Attempted: ipfs-cluster Partial log (click to expand)
|
Success on x86_64-darwin (full log) Attempted: ipfs-cluster Partial log (click to expand)
|
aarch64 failure is unrelated (in a dependency). |
Motivation for this change
I've been using the ipfs-cluster recently, but there was no nixpkg to build it. This adds the ipfs-cluster nixpkg (which includes the
ipfs-cluster-service
andipfs-cluster-ctl
binaries).Longer term, it might be nice to add some of the ipfs-cluster-service functionality to the ipfs NixOS service itself, but I'll until I have more experience using ipfs-cluster to tackle that.
There was only one complication. The ipfs-cluster repo keeps the go imports in the "github.com/" format, but when the GX package manager (called by
fetchgx
) gets the packages, it stores them in thesrc/
directory by their IPFS hash in "gx/ipfs". I added apreBuild
step to rewrite these paths using thegx-go
utility.Things done
sandbox
innix.conf
on non-NixOS)nix-shell -p nox --run "nox-review wip"
./result/bin/
)nix path-info -S
before and after)