Home Explore Blog Models CI



nix

src/libstore/local-binary-cache-store.md
fe326b4a80037a0f64a5cfc8ed767ba98b9ca95ca4ad82ec0000000300000191
R"(

**Store URL format**: `file://`*path*

This store allows reading and writing a binary cache stored in *path*
in the local filesystem. If *path* does not exist, it will be created.

For example, the following builds or downloads `nixpkgs#hello` into
the local store and then copies it to the binary cache in
`/tmp/binary-cache`:

```
# nix copy --to file:///tmp/binary-cache nixpkgs#hello
```

)"

Chunks
039a59a5 (1st chunk of `src/libstore/local-binary-cache-store.md`)
Title: Local Filesystem Binary Cache (`file://` URL)
Summary
This document describes the `file://` URL format for a binary cache, which enables reading and writing a binary cache directly on the local filesystem. The specified path will be created if it does not already exist. An example command `nix copy --to file:///tmp/binary-cache nixpkgs#hello` demonstrates copying a package to such a local binary cache.