Peer2Peer Nix-Binary-Cache
|
Mohamed Laradji
3f4d7d5428
Flake lock file updates: • Updated input 'flake-compat': 'github:edolstra/flake-compat/35bb57c0c8d8b62bbfd284272c928ceb64ddbde9' (2023年01月17日) → 'github:edolstra/flake-compat/0f9255e01c2351cc7d116c072cb317785dd33b33' (2023年10月04日) • Updated input 'flake-utils': 'github:numtide/flake-utils/3db36a8b464d0c4532ba1c7dda728f4576d6d073' (2023年02月13日) → 'github:numtide/flake-utils/ff7b65b44d01cf9ba6a71320833626af21126384' (2023年09月12日) • Added input 'flake-utils/systems': 'github:nix-systems/default/da67096a3b9bf56a91d16901293e51ba5b49a27e' (2023年04月09日) • Updated input 'nixpkgs': 'github:NixOS/nixpkgs/5798b8c569396eca709a18d5391d4e18fc5124db' (2023年02月24日) → 'github:NixOS/nixpkgs/7131f3c223a2d799568e4b278380cd9dac2b8579' (2023年10月04日) |
||
|---|---|---|
| peerix | Fix store path contains illegal character ' ' error | |
| .editorconfig | add .editorconfig | |
| .envrc | Initial commit | |
| .gitignore | Make default.nix work. | |
| COPYING | Add GPL to the application | |
| default.nix | nix: Switch to nix-flakes. | |
| flake.lock | flake.lock: Update | |
| flake.nix | Merge #7 | |
| module.nix | fix(systemd): correct parameter to SystemCallFilter, without the s | |
| overlay.nix | add overlay | |
| README.md | README: Add new option | |
| requirements.txt | some better broadcasting. | |
| setup.py | Actually include some packages | |
| shell.nix | nix: Switch to nix-flakes. | |
| VERSION | fix: respect newline preferences of some editors | |
Peerix
Peerix is a peer-to-peer binary cache for nix derivations. Every participating node can pull derivations from each other instances' respective nix-stores.
How does it work?
Peerix implements a nix binary cache. When the nix package manager queries peerix, peerix will ask the network if any other peerix instances hold the package, and if some other instance holds the derivation, it will download the derivation from that instance.
Installation
There is a nix-module located at module.nix that configures your nixos-installation
to automatically use peernix.
These Options exist:
| Option | Description |
|---|---|
services.peerix.enable |
Enables Peerix |
services.peerix.openFirewall |
Open the neccessary firewall ports. |
services.peerix.user |
What user should the peerix service run under. |
services.peerix.group |
What group should the peerix service run under. |
services.peerix.privateKeyFile |
A path to the file that contains the path to the private key to sign your derivations. |
services.peerix.publicKeyFile |
A path to the file that contains the path to the public key so nix can verify the signature. |
services.peerix.publicKey |
Directly specifiy a public key for the binary caches. |
To sign the peerix cache, you can use nix-store --generate-binary-cache-key to create keys to verify authenticity of
the packages in each nix-store.