-
Notifications
You must be signed in to change notification settings - Fork 6
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
Create K8s deployment of Nix cache for space.cloudnative.nz #36
Comments
PR will go https://github.com/cloudnative-nz/space-infra/tree/main/cluster |
Use
|
Am documenting my progress in #37 , which is mostly an org file that I have included below... Table of Contents
IntroductionThis is a diary file related to the ticket Create k8s deployment of nix cache for space.cloudnative.nz The goal is to have our own nix binary cache server that can be used across our workspaces. What is a binary cache?When you build a nix derivation, it results in a binary file stored in your They have a wiki explaining how to set up a binary cache server here: However, this explains how to set it up on a nixOS machine. The basic setup they Running nix-serve as a docker imageWe ultimately want a docker image that we can use as part of a k8s deployment. I checked out the repo for nix-serve, and there is an open issue about publishing it as a docker image: They answers advise against this, saying that it’d be simpler to just deploy an I experimented a bit with creating the nginx image and pushing the binary files nix cache binary using s3 minioThere is an interesting article about building your own s3 cache server. It is cachix and nginxA more interesting setup to me is in this blog: This is real simple, at its heart. They set up some cache servers using cachix, I think this could be useful for our own work. Cachix handles the key creation Current planAt this point, I outlined a basic plan..which was to write a simple package, I made a simple package called zhello, documented in this repo ii/nix-flake-example I should be able to use this package on my local machine, even if it doesn’t exist yet,
Notice the extra nix config. This uses a substituter that says to look at our However, this does not work. There is no attribute in nixpkgs called zhello. At this point, I realized that I didn’t fully understand how the publishing of this link is a nice guide, tho not exactly what we’re trying to do: We coudl try to test it instead with something like the hello package, something I want to have custom packages in binary cache server that can have multiple cache servers running in front of it. |
Nix flakes + Dir ENV to bring up a devshell for:
The text was updated successfully, but these errors were encountered: