[contd convo with @Andreas ]
I've been recommending people use nix run github:...
for installing some of my software like Emanote, nixci, nix-health (especially as they are out-of-date on the increasingly unwieldy monorepo nixpkgs).
To that end, I want to setup a small package set without IFD, providing cache for Linux and mac.
I could expose the local nix store via nix-serve-ng
, but https://github.com/zhaofengli/attic is probably the more reliable option down the line, especially for dealing with larger builds/caches (at work).
Yes, I was thinking about using something like attic. That might be a neat thing. IIRC it also just acts as a kind of cache overlay on cache.nixos.org, so everything that is not in your specialized cache is just forwarded to the larger official one.
For setting this up you would need some hardware though I guess, and an S3 compatible storage provider of some kind. And I was wondering how much storage and bandwidth you might need for your existing Haskell packages.
I think attic supports local storage too, if you just want store them in local disk to begin with.
As for bandwidth, for my personal projects the 1 Gbits/s should probably be good enough to begin with.
Of course cache is useless without a CI that pushes to it. For this I've been exploring GitHub runners (topic here), and eventually want to set one up on my macbook as well.
Yes it does support local storage. Which might be sufficient, right.
I was just wondering what happens to your storage if your machine goes down for whatever reason.
If store gets corrupt and recreated, just do a rebuild. There aren't a lot to rebuild.
Need to figure out a smart gcroot pinning system, that works with CI along with these 'recovery' instances.
a smart gcroot pinning system
I am not quite sure I am following on this one
garbage collect everything but last N commits of stable (and desired) branches of repos.
https://github.com/hercules-ci/hercules-ci-agent/issues/482
Maybe the attic tutorial https://docs.attic.rs/tutorial.html is interesting, too. It comes with some kind of garbage collection capabilities.
FWIW, for me, digitalocean spaces is super cheap ($5 p/m) and putting it behind cloudflare CDN is free. Also they allow an unlimited number of buckets so long as you don't go over 500G so you could have multiple caches if you wanted to
500G
Cloudflare R2? What did you get this number from?
Oh I guess I misremembered, it's 250G
(for $5)
Any reason why I shouldn't put the cache data on one of these? https://www.hetzner.com/storage/storage-box/
Srid said:
Any reason why I shouldn't put the cache data on one of these? https://www.hetzner.com/storage/storage-box/
Do you have full SSH access to these? Not really, right. Not sure what you are planing but for attic is would probably be nice to get NixOS with Minio or something similar.
Last updated: Nov 15 2024 at 11:45 UTC