1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-08 19:46:02 +01:00

libstore: Move {narinfo,ls,log}-compression settings from BinaryCacheStoreConfig to HttpBinaryCacheStoreConfig

These settings are only implemented for the http store and should not be
there for the file:// stores.
This commit is contained in:
Sergei Zimmerman 2025-10-02 23:11:16 +03:00
parent dc8c1461da
commit d2017e0e1a
No known key found for this signature in database
2 changed files with 15 additions and 15 deletions

View file

@ -59,21 +59,6 @@ struct BinaryCacheStoreConfig : virtual StoreConfig
The meaning and accepted values depend on the compression method selected.
`-1` specifies that the default compression level should be used.
)"};
const Setting<std::string> narinfoCompression{
this, "", "narinfo-compression", "Compression method for `.narinfo` files."};
const Setting<std::string> lsCompression{this, "", "ls-compression", "Compression method for `.ls` files."};
const Setting<std::string> logCompression{
this,
"",
"log-compression",
R"(
Compression method for `log/*` files. It is recommended to
use a compression method supported by most web browsers
(e.g. `brotli`).
)"};
};
/**

View file

@ -17,6 +17,21 @@ struct HttpBinaryCacheStoreConfig : std::enable_shared_from_this<HttpBinaryCache
ParsedURL cacheUri;
const Setting<std::string> narinfoCompression{
this, "", "narinfo-compression", "Compression method for `.narinfo` files."};
const Setting<std::string> lsCompression{this, "", "ls-compression", "Compression method for `.ls` files."};
const Setting<std::string> logCompression{
this,
"",
"log-compression",
R"(
Compression method for `log/*` files. It is recommended to
use a compression method supported by most web browsers
(e.g. `brotli`).
)"};
static const std::string name()
{
return "HTTP Binary Cache Store";