mkBinaryCache: support different compression methods: xz (default), zstd, none

This commit is contained in:
thomasjm
2025-01-05 00:24:37 -08:00
committed by Tom McLaughlin
parent 2f5bd177a3
commit 00a218abb2
6 changed files with 82 additions and 24 deletions

View File

@@ -11,6 +11,14 @@ It can also be a convenient way to make some Nix packages available inside a con
`rootPaths` must be a list of derivations.
The transitive closure of these derivations' outputs will be copied into the cache.
## Optional arguments {#sec-pkgs-binary-cache-arguments}
`compression` (`"none"` or `"xz"` or `"zstd"`; _optional_)
: The compression algorithm to use.
_Default value:_ `zstd`.
::: {.note}
This function is meant for advanced use cases.
The more idiomatic way to work with flat-file binary caches is via the [nix-copy-closure](https://nixos.org/manual/nix/stable/command-ref/nix-copy-closure.html) command.

View File

@@ -1959,6 +1959,9 @@
"sec-pkgs-binary-cache": [
"index.html#sec-pkgs-binary-cache"
],
"sec-pkgs-binary-cache-arguments": [
"index.html#sec-pkgs-binary-cache-arguments"
],
"sec-pkgs-binary-cache-example": [
"index.html#sec-pkgs-binary-cache-example"
],