Caching
Always build locally
No matter the system, build config for local system and only use them locally.
Good
- Do not need to rely on extra infra.
- Simply build what you need when you need it.
Bad
- Some config could be useful for other machines and will be have to built
again.
Push local builds to cache
After building locally we push the results to accessible cache.
Good
- Shares build outputs avoid rebuilding same derivations.
Bad
- Local config could have sensitive derivations and this would risk pushing
them over the internet to a possibly vulnerable or overly accessible location,
Push common builds to cache
When common builds or nixpkgs is updated push common builds with nixpkgs using
sample config to cache.
Good
- Pushes most of what will be shared between systems.
- Work is done before needed for systems.
- No sensitive derivations at risk of being exposed.
- Need to do the work for testing anyways.
Bad
??