Nix - Namespace Documentation
Documentation Index
Fetch the complete documentation index at: /docs/llms.txt
Use this file to discover all available pages before exploring further.
Assistant
Responses are generated using AI and may contain mistakes.
nixcache is a local HTTP binary-cache proxy backed by Namespace blobstorage. It combines a local disk cache with shared storage, so a fresh runner can reuse cached Nix outputs without landing on the machine that built them.
Nix caching is in early access. Contact support to set up a cache namespace and the credentials your workflows need.
The proxy supports Linux and macOS on amd64 and arm64. It works with an existing Nix installation and does not change where builds execute. You can also use it on a remote Nix builder; configure each machine that needs to substitute or publish outputs.
Install nixcache
Install the latest released binary:
curl -fsSL https://public.namespaceblobs.com/nixcache/install.sh | sh
The installer verifies the archive’s SHA-256 checksum and installs to ~/.local/bin/nixcache without sudo by default. It requires curl, tar, sed, awk, and either sha256sum or shasum. It does not install Nix, modify Nix configuration, or start the proxy.
Start the proxy
After cache access is enabled for your workspace, start the proxy:
if [ -n "${NSC_CACHE_PATH:-}" ]; then
cache_root="$NSC_CACHE_PATH"
elif [ "$(uname -s)" = Darwin ]; then
cache_root="$HOME/Library/Caches"
else
cache_root="${XDG_CACHE_HOME:-$HOME/.cache}"
fi
~/.local/bin/nixcache \
-cache_dir "$cache_root/nixcache"
The command starts a background process and returns once the listener is ready. It prints the listener address, PID, and log path. The default address is http://127.0.0.1:18765.The example prefers the Cache Volume at NSC_CACHE_PATH to reuse local downloads across jobs. Without a volume, it uses the OS user cache directory: ~/Library/Caches on macOS, or XDG_CACHE_HOME with a fallback to ~/.cache on Linux. The examples below reuse this cache_root variable.-cache_dir selects a dedicated local directory for cached archives and staged uploads. Without it, the proxy uses temporary storage that is removed on clean shutdown. Shared blobstorage remains available to other runners regardless of the local directory.
Authentication
On Namespace instances, nixcache automatically uses the instance’s credentials.On other machines, sign in with nsc login before starting the proxy:
nsc login
The credentials must have access to the cache namespace.
Configure Nix
Add these settings to your Nix configuration to route substitution through the proxy:
substituters = http://127.0.0.1:18765
require-sigs = true
Keep Nix’s standard cache.nixos.org-1 trusted public key. Public packages retain their original signatures, so no additional key is required for the default public fallback.For multi-user Nix, set these options in the daemon’s configuration, normally /etc/nix/nix.conf, and reload or restart the daemon as required by your Nix installation. The daemon must be able to reach the proxy’s loopback address. A proxy running inside a different container or network namespace is not reachable at the daemon’s 127.0.0.1.Use extra-substituters instead of substituters if you want to retain other configured caches. Keeping https://cache.nixos.org as a direct substituter lets Nix bypass the proxy, so those downloads may not populate the Namespace cache.After configuration, ordinary Nix commands use the cache:
nix build .#your-package
Replace your-package with an output from your project. This example uses flakes and the nix command, which must be enabled in your Nix installation.
Public-cache fallback
By default, nixcache falls back to https://cache.nixos.org for entries missing from Namespace blobstorage. It downloads archives into the local cache using parallel byte ranges and serves available bytes to Nix before the full download completes.Choose how upstream entries are cached with -cache-upstream:
| Mode | Behavior |
|---|---|
persist (default) |
Fetch missing entries from the public upstream, cache archives locally, and publish entries to Namespace blobstorage in the background. Requires write access to populate shared storage. |
local-only |
Fetch missing entries from the public upstream and cache archives locally, without publishing fallback entries to blobstorage. Use this with read-only credentials. |
off or disabled |
Disable public fallback. Continue serving local and blobstorage entries. Explicit uploads remain enabled. |
For example, restrict a consumer to entries already available in Namespace:
~/.local/bin/nixcache \
-cache_dir "$cache_root/nixcache" \
-cache-upstream=off
Namespace credentials are never sent to the public upstream.Fallback happens only on a blobstorage not-found response. Authentication failures, throttling, and storage outages do not trigger public fallback. Namespace credentials are still required in local-only mode.In persist mode, the proxy publishes the archive before its original .narinfo metadata. It preserves Nix hashes and signatures, so no private signing key is needed to mirror public packages. Once publication finishes, another runner can fetch the entry from blobstorage even with fallback disabled.Publication is asynchronous and best-effort. Failures are logged without interrupting the read. If a job must populate shared storage, allow publication to finish before stopping the proxy: a fallback entry stored log for a .narinfo path confirms that its archive and metadata were published. Stopping the proxy cancels pending publication.
Publish your own builds
Trusted CI needs cache write access and a Nix private signing key. Follow the authentication instructions, then publish a built output and its dependencies using native nix copy:
~/.local/bin/nixcache \
-cache_dir "$cache_root/nixcache-writer"
nix build .#your-package
nix copy \
--to 'http://127.0.0.1:18765?secret-key=/run/secrets/cache-private.key' \
./result
Run the writer instead of the reader proxy on that machine, or assign separate loopback ports with -listen and update the URLs accordingly. Replace the signing-key path with a file provisioned by your CI secret manager.secret-key is a native Nix store URI setting. Nix reads the signing key locally; it is not sent to the proxy. No separate upload client is required.Consumers of your signed outputs must add the corresponding public key to their Nix configuration:
extra-trusted-public-keys = MY-CACHE:BASE64_PUBLIC_KEY
Replace the placeholder with your cache’s public signing key. Keep require-sigs = true and retain any upstream public keys you use.
Isolate untrusted forks
Give fork jobs credentials with only namespace-scoped blobs read access. Trusted CI uses separate writer credentials and holds the private signing key. Support can help configure these permissions during early access.
-cache-upstream=local-only disables automatic fallback publication, not writes. Blobstorage enforces access permissions. Any process that can reach the proxy can use its credential’s permissions, so never expose a writer proxy, writer credential, private signing key, or writable trusted cache directory to untrusted jobs.
Use a separate proxy and local cache directory for each trust boundary. Public signing keys can be shared with readers; private keys cannot.
Operation and troubleshooting
Background logs are written to cache_dir/cacheproxy.log when -cache_dir is set. Use -log_file to choose another location, or -foreground to run under a process supervisor and log to the terminal. Logs include HTTP access and download or publication failures.At startup, the proxy removes unfinished downloads and staged uploads while preserving completed local entries. Stop it with kill -TERM <printed-pid> during job cleanup. There is no local eviction policy yet: budget disk space for downloads and concurrent uploads, and remove old cache directories while the proxy is stopped.Local cache entries are partitioned by storage endpoint, namespace, upstream URL, and credential scope. Token rotation can cause cold local reads; a persistent directory does not guarantee a local hit across credential changes.
Remote builders
Namespace compute instances can also run as remote Nix builders using Nix’s distributed builds feature. Remote builders execute builds; nixcache stores and serves their outputs. You can use either independently or configure the cache on your remote builders as well.The following steps prepare an instance with Nix and nixcache installed. Enable cache access for the workspace first, as described under authentication.
1
Create a bare compute instance
Create a new compute instance with your SSH key:
nsc create --bare --ssh_key ~/.ssh/id_ed25519.pub
You can use an existing SSH key or create a new one specifically for this purpose with ssh-keygen -t ed25519.Grab the instance ID from the output.
2
Install Nix on the remote instance
SSH into the instance and install Nix using the Determinate installer:
ssh <id>@ssh.ord2.namespace.so "curl -fsSL https://install.determinate.systems/nix | sh -s -- install linux --determinate --init none --no-confirm"
Bare instances run as root and do not require sudo. With --init none, the installer leaves the Nix daemon stopped and may report a missing daemon socket during its self-test. Start it after configuring the cache below.
3
Install and start nixcache on the builder
Run the following from your client. The quoted heredoc keeps the environment variables on the remote instance, so the cache directory belongs to the builder rather than your client:
ssh <id>@ssh.ord2.namespace.so 'bash -s' <<'EOF'
set -eu
curl -fsSL https://public.namespaceblobs.com/nixcache/install.sh | sh
cache_root="${NSC_CACHE_PATH:-${XDG_CACHE_HOME:-$HOME/.cache}}"
~/.local/bin/nixcache -cache_dir "$cache_root/nixcache"
EOF
This Linux example prefers the instance’s Cache Volume when available. The proxy uses the instance’s credentials and defaults to -cache-upstream=persist to publish public packages to shared storage.
4
Configure Nix on the builder
Add a separate configuration file and include it from nix.custom.conf, which the Determinate installer reserves for user settings:
ssh <id>@ssh.ord2.namespace.so 'bash -s' <<'EOF'
set -eu
cat > /etc/nix/nixcache.conf <<'CONF'
substituters = http://127.0.0.1:18765
require-sigs = true
CONF
if ! grep -qxF '!include nixcache.conf' /etc/nix/nix.custom.conf; then
printf '\n!include nixcache.conf\n' >> /etc/nix/nix.custom.conf
fi
EOF
Keep the existing trusted public keys. Determinate also adds its own installer substituter; the default cache.nixos.org route now goes through the proxy.
5
Start the Nix daemon
Start the daemon once on this fresh instance. Redirect its input and output so it remains running after SSH disconnects:
ssh <id>@ssh.ord2.namespace.so 'bash -s' <<'EOF'
set -eu
nohup /nix/var/nix/profiles/default/bin/nix-daemon \
> /var/log/nix-daemon.log 2>&1 < /dev/null &
EOF
On an existing builder with a running daemon, restart that daemon after configuration changes instead of starting a second one.
6
Test the installation
Run a package on the builder. Nix uses the builder’s local proxy for substitution, which falls back to cache.nixos.org on a shared-cache miss:
ssh <id>@ssh.ord2.namespace.so nix run nixpkgs#hello
If the package is already in the builder’s Nix store, Nix does not need to fetch it again. Check the proxy’s access logs to see which requests reached the cache.
Follow Nix’s distributed-build configuration to connect your client to this instance. Enable builders-use-substitutes = true on the client to let remote builders fetch available dependencies from their configured substituters instead of copying them from the client. The proxy must run on the builder: its 127.0.0.1 is separate from the client’s.Building an output does not automatically publish it. Use the signed publication instructions on the builder to share your own outputs with other machines.
Last modified onSeptember 15, 2026
Ctrl+I
{"docsConfig":{"theme":"almond","$schema":"https://mintlify.com/docs.json","name":"Namespace Documentation","colors":{"primary":"#1C32FF","light":"#6B78FF","dark":"#1C32FF"},"logo":{"light":"https://mintcdn.com/namespace-labs/qOJQ7kaWRgoS8lyv/logo-light.svg?fit=max\\u0026auto=format\\u0026n=qOJQ7kaWRgoS8lyv\\u0026q=85\\u0026s=6827b0c81c335badc1cef13b83383e1d","dark":"https://mintcdn.com/namespace-labs/qOJQ7kaWRgoS8lyv/logo-dark.svg?fit=max\\u0026auto=format\\u0026n=qOJQ7kaWRgoS8lyv\\u0026q=85\\u0026s=63702d83d8fb259023deb79db06aabbb","href":"https://namespace.so"},"favicon":"https://mintcdn.com/namespace-labs/MoefQ379UcpNU680/favicon.svg?fit=max\\u0026auto=format\\u0026n=MoefQ379UcpNU680\\u0026q=85\\u0026s=6f14a088da55e5f41847845796737353","navbar":{"links":\[{"href":"https://namespace.so/changelog","label":"Changelog"},{"href":"https://namespace.so/support","label":"Support"}\],"primary":{"type":"button","label":"Log in","href":"https://cloud.namespace.so"}},"footer":{"socials":{"github":"https://github.com/namespacelabs","linkedin":"https://www.linkedin.com/company/namespacelabs","x":"https://x.com/namespacelabs"}},"icons":{"library":"lucide"},"contextual":{"options":\["copy","view","chatgpt","claude"\],"display":"header"},"interaction":{"drilldown":false},"metadata":{"timestamp":true},"styling":{"latex":true},"navigation":{"global":{"anchors":\[{"anchor":"Changelog","icon":"history","href":"https://namespace.so/changelog"},{"anchor":"Trust Center (SOC2)","icon":"shield-check","href":"https://trust.namespace.so/"},{"anchor":"Status","icon":"activity","href":"https://namespace-status.com/"},{"anchor":"Support","icon":"message-circle","href":"https://namespace.so/support"}\]},"pages":\[\]}},"deployment":{"deploymentMetadataValue":{"subdomain":"namespace-labs","hasAudioNarration":false,"actualSubdomain":"namespace-labs","customDomains":\["namespace.so"\],"gitSource":{"type":"github","owner":"namespacelabs","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"latestBuiltDeploymentHistoryId":"6ae0862207896b4595e1934b","collectionId":"847aecca-4a0b-40b4-a393-e976cc214b43","liveDeploymentHistoryId":"6ae0862207896b4595e1934b","schemaVersion":"v3"},"entitlements":{"AI\_CHAT":{"status":"ENABLED"},"WEB\_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ae0a8f6edbd4c098a94623c","clientVersion":"0.0.3971","searchFilterCounts":\[{"language":"default","tag":"Products","count":377},{"language":"default","tag":"CLI","count":166},{"language":"default","tag":"Command line","count":165},{"language":"default","tag":"Namespace CLI","count":131},{"language":"default","tag":"Documentation","count":104},{"language":"default","tag":"GitHub Actions","count":40},{"language":"default","tag":"Devbox CLI","count":34},{"language":"default","tag":"Integrations","count":33},{"language":"default","tag":"SDK","count":25},{"language":"default","tag":"Namespace SDK","count":23}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":true},"customCss":[{"filePath":"snippets/diagrams/styles.css","content":".ns-diagram{--ns-diagram-background:#ffffff;--ns-diagram-grid:#e5e7ee;--ns-diagram-border:#e5e7ee;--ns-diagram-card:#ffffff;--ns-diagram-neutral-zone:#fafbfc;--ns-diagram-brand-zone-start:rgba(28, 50, 255, 0.04);--ns-diagram-brand-zone-end:rgba(28, 50, 255, 0.07);--ns-diagram-brand-border:#c8ceff;--ns-diagram-heading:#202938;--ns-diagram-muted:#8892a6;--ns-diagram-copy:#4a5468;position:relative;width:100%;margin:2rem 0;padding:clamp(20px,3.5vw,32px);overflow:hidden;color:var(--ns-diagram-heading);background:var(--ns-diagram-background);border:1px solid var(--ns-diagram-border);border-radius:20px;box-shadow:0 1px 0 rgba(32,41,56,.04),0 1px 2px rgba(32,41,56,.06)}.dark .ns-diagram{--ns-diagram-background:#111827;--ns-diagram-grid:#374151;--ns-diagram-border:#374151;--ns-diagram-card:#1f2937;--ns-diagram-neutral-zone:#171f2d;--ns-diagram-brand-zone-start:rgba(107, 120, 255, 0.1);--ns-diagram-brand-zone-end:rgba(107, 120, 255, 0.16);--ns-diagram-brand-border:#4f5fc7;--ns-diagram-heading:#f3f4f6;--ns-diagram-muted:#aeb6c5;--ns-diagram-copy:#cbd5e1}.ns-diagram-grid-background{position:absolute;inset:0;pointer-events:none;background-image:radial-gradient(circle,var(--ns-diagram-grid) 1px,transparent 1px);background-size:16px 16px;opacity:.5;mask-image:linear-gradient(180deg,transparent 0,#000 10%,#000 90%,transparent 100%)}.ns-diagram-content{position:relative}.ns-diagram-caption{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.ns-diagram-mark{display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;margin:0;border-radius:8px}.ns-diagram-mark-anthropic{color:#d97757;background:#fcefe8}.ns-diagram-mark-devin{color:#4338ca;background:#eef0ff}.ns-diagram-mark-cursor{color:#111827;background:#eef0f3}.ns-diagram-mark-control{color:#1c32ff;background:#e0e7ff}.ns-diagram-mark-terminal{color:#fff;background:#202938}.ns-diagram-mark-worker{color:#4338ca;background:#eef1ff}.ns-diagram-zone{position:relative;display:flex;flex-direction:column;padding:1.25rem;background:var(--ns-diagram-neutral-zone);border:1px dashed #d2d6e0;border-radius:14px}.dark .ns-diagram-zone{border-color:#4b5563}.ns-diagram-zone-brand{background:linear-gradient(180deg,var(--ns-diagram-brand-zone-start),var(--ns-diagram-brand-zone-end));border:1px solid var(--ns-diagram-brand-border)}.ns-diagram-zone-header{display:flex;align-items:center;gap:.5rem;margin-bottom:.75rem;color:var(--ns-diagram-copy);font-size:11px;font-weight:600;letter-spacing:.1em;text-transform:uppercase}.ns-diagram-zone-center{display:flex;flex:1;align-items:center}.ns-diagram-zone-center>*{width:100%}.ns-diagram-card{position:relative;display:flex;align-items:center;gap:1rem;min-width:0;padding:1rem 1.25rem;background:var(--ns-diagram-card);border:1px solid var(--ns-diagram-border);border-radius:12px;box-shadow:0 1px 0 rgba(32,41,56,.04),0 1px 2px rgba(32,41,56,.06)}.ns-diagram-card-brand{border-color:var(--ns-diagram-brand-border)}.ns-diagram-card-copy{display:flex;min-width:0;flex-direction:column}.ns-diagram-card-label{color:var(--ns-diagram-heading);font-size:16px;font-weight:600;line-height:1.25;letter-spacing:-.01em}.ns-diagram-card-sublabel{margin-top:.125rem;color:var(--ns-diagram-muted);font-size:12px;line-height:1.35}.ns-managed-layout{display:grid;grid-template-columns:1fr auto 1.05fr;align-items:stretch}.ns-managed-connector{display:flex;width:64px;flex-direction:column;align-items:center;justify-content:center;padding:0 .25rem;color:var(--ns-diagram-muted);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:10.5px}.ns-managed-connector>span{margin-bottom:.375rem}.ns-managed-connector-path{display:flex;width:56px;align-items:center}.ns-managed-connector-line{flex:1;height:1.5px;background:#d2d6e0}.ns-managed-connector-arrow{border-top:6px solid transparent;border-bottom:6px solid transparent;border-left:9px solid #d2d6e0}.ns-mini-connector{display:flex;flex-direction:column;align-items:center;padding:.375rem 0}.ns-mini-connector>div{width:1.5px;height:12px;background:var(--ns-diagram-brand-border)}.ns-mini-connector>span{border-top:7px solid var(--ns-diagram-brand-border);border-right:5px solid transparent;border-left:5px solid transparent}.ns-devin-devboxes,.ns-devin-sessions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1.5rem}.ns-devin-mobile-layout{display:none}.ns-devin-connectors,.ns-devin-connectors>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.ns-devin-connectors{gap:1.5rem}.ns-devin-connectors>div{padding:0 1rem}.ns-devin-connector{position:relative;display:flex;min-height:110px;align-items:center;justify-content:center;color:var(--ns-diagram-copy);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:10px;line-height:1.25;text-align:center}.ns-devin-management-connector{min-height:70px;color:#6366f1}.ns-devin-connector-line{position:absolute;top:0;bottom:0;left:50%;width:1.5px;background:#d2d6e0;transform:translateX(-50%)}.ns-devin-management-connector .ns-devin-connector-line,.ns-diagram-connector-dashed .ns-diagram-vertical-line{width:0;background:0 0;border-left:1.5px dashed var(--ns-diagram-brand-border)}.ns-devin-connector>span,.ns-diagram-vertical-connector>span{position:relative;z-index:1;padding:0 .375rem;background:var(--ns-diagram-background)}.ns-control-plane-pill{display:flex;align-items:center;align-self:center;gap:.375rem;margin-bottom:1rem;padding:.375rem .75rem;color:#4338ca;background:#eef1ff;border:1px solid var(--ns-diagram-brand-border);border-radius:999px;font-size:12px;font-weight:500}.ns-diagram-vertical-connector{position:relative;display:flex;align-items:center;justify-content:center;color:var(--ns-diagram-copy);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:10px;line-height:1.25;text-align:center}.ns-diagram-vertical-line{position:absolute;top:0;bottom:0;left:50%;width:1.5px;background:#d2d6e0;transform:translateX(-50%)}.ns-diagram-connector-dashed{color:#6366f1}.ns-diagram-arrow-down{position:absolute;bottom:0;left:50%;border-top:8px solid #d2d6e0;border-right:5px solid transparent;border-left:5px solid transparent;transform:translateX(-50%)}.ns-devin-management-connector .ns-diagram-arrow-down,.ns-diagram-connector-dashed .ns-diagram-arrow-down{border-top-color:var(--ns-diagram-brand-border)}.ns-bazel-connector-inset{padding:0 1rem}.ns-bazel-workers{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}@media (max-width:767px){.ns-managed-layout{grid-template-columns:1fr}.ns-managed-connector{position:relative;width:auto;min-height:64px;padding:.5rem 0}.ns-managed-connector-path{width:auto;flex-direction:column}.ns-managed-connector-line{width:1.5px;height:24px;flex:none}.ns-managed-connector-arrow{border-top:9px solid #d2d6e0;border-right:6px solid transparent;border-bottom:0;border-left:6px solid transparent}.ns-devin-connectors,.ns-devin-devboxes,.ns-devin-sessions{grid-template-columns:1fr}.ns-devin-desktop-layout{display:none}.ns-devin-mobile-layout{display:block}.ns-devin-mobile-lane+.ns-devin-mobile-lane{margin-top:1.5rem;padding-top:1.5rem;border-top:1px solid var(--ns-diagram-border)}.ns-devin-mobile-connectors{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));padding:0 .5rem}.ns-devin-connector{min-height:80px}.ns-bazel-workers{grid-template-columns:1fr}}"},{"filePath":"style.css","content":":root{--namespace-radius-inline:0.25rem;--namespace-radius-control:0.375rem;--namespace-radius-container:0.5rem}#content-container,.almond-layout>div,.card,.chat-assistant-floating-input>div,.code-block,.frame,.pagination-next,.pagination-prev{border-radius:var(--namespace-radius-container)}.code-block [data-component-part=code-block-root],.frame>div{border-radius:inherit}#assistant-entry,#chat-assistant-textarea,#search-bar-entry,#search-input,.callout,.frame>.relative{border-radius:var(--namespace-radius-control)}.code-block-fade-overlay{border-radius:0 var(--namespace-radius-container) var(--namespace-radius-container) 0}#page-context-menu>button:first-child{border-radius:var(--namespace-radius-control) 0 0 var(--namespace-radius-control)}#page-context-menu>button:last-child{border-radius:0 var(--namespace-radius-control) var(--namespace-radius-control) 0}#content :not(pre)>code,#navigation-items li>a,#navigation-items li>button{border-radius:var(--namespace-radius-inline)}#navigation-items .nav-anchor>:is(svg, img),#navigation-items .sidebar-group-icon,#navigation-items [data-component-part=scroll-area-content]:has(>ul.nav-anchors),#navigation-items li>:is(a, button)>div[class=\"h-[1lh]\"]:first-child{display:flex;flex-direction:column}#navigation-items [data-component-part=scroll-area-content]>ul.nav-anchors{order:1;margin-top:1rem;padding-top:1rem;border-top:1px solid color-mix(in srgb,currentColor 10%,transparent)}#navigation-items [data-component-part=scroll-area-content]>ul.sidebar-group{margin-top:.5rem}#navigation-items [data-component-part=scroll-area-content]>ul.sidebar-group+div{margin-top:1rem}.tab-container{overflow:hidden;padding:0 1rem 1rem;border:1px solid color-mix(in srgb,currentColor 12%,transparent);border-radius:var(--namespace-radius-container)}.tab-container [data-component-part=tab-content]>[data-table-wrapper]:last-child{margin-bottom:0;padding-bottom:0}#content .katex-display>.katex{text-align:left}.compact-table table td{min-width:0}#navigation-items ul.sidebar-group>li.space-y-px+li.space-y-px{margin-top:.75rem}#navigation-items .my-2>.sidebar-group-header{margin-bottom:.625rem;font-size:.8125rem;line-height:1.625rem;font-weight:600;letter-spacing:-.02em;text-transform:none;opacity:1}#navigation-items ul.sidebar-group>li.space-y-px>button{font-size:.8125rem;font-weight:600;letter-spacing:-.02em;background-color:transparent}#navigation-items ul.sidebar-group>li.space-y-px>button:hover,#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>button:hover{background-color:color-mix(in srgb,currentColor 6%,transparent)}#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>button,#navigation-items ul.sidebar-group>li.space-y-px>ul>li>a{padding-left:3rem!important;font-size:.8125rem;font-weight:400;letter-spacing:-.02em}#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>ul>li[data-active-nav-item=true]>a,#navigation-items ul.sidebar-group>li.space-y-px>ul>li[data-active-nav-item=true]>a{color:#121516!important;background-color:rgb(18 21 22/6%)!important}.dark #navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>ul>li[data-active-nav-item=true]>a,.dark #navigation-items ul.sidebar-group>li.space-y-px>ul>li[data-active-nav-item=true]>a{color:#f4f4f5!important;background-color:rgb(255 255 255/8%)!important}#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>button{background-color:transparent}#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>button>div[class=\"h-[1lh]\"]:first-child{margin-left:-1.75rem}.dark #navigation-items img[src*=buildkite-mark]{filter:brightness(.7)}.dark img[src*=\"/icons/apple.svg\"]{filter:invert(1)}.dark img.tab-icon[src*=\"/icons/linux.svg\"]{filter:invert(.35) brightness(1.54)}#navigation-items ul.sidebar-group>li.space-y-px>ul>li.space-y-px>ul>li>a{padding-left:4rem!important;font-size:.8125rem;font-weight:400;letter-spacing:-.02em}@media (min-width:1024px){#sidebar-content{width:calc(16.5rem + 10px)}#content-container{margin-left:calc(16.5rem + 10px)}#navbar{container-type:inline-size}#navbar .nav-tabs{position:fixed;top:0;left:20rem;height:3.5rem;column-gap:2rem}#navbar div:has(>div>.nav-tabs){justify-content:flex-end}@container (max-width: 69rem){#navbar .navbar-link:has(>a[href=\"https://namespace.so/changelog\\"\]){display:none}}}@media (min-width:1280px){#content-container{padding-right:1.5rem;padding-left:3rem}#content-container>div{column-gap:1.5rem;justify-content:flex-start}#content-area{width:calc(100% - 13.5rem);max-width:52rem;flex:none}#content-side-layout{width:15rem;max-width:15rem;flex-basis:15rem}#content-side-layout>div{width:15rem;padding-left:1rem}#content-side-layout>div>div{width:14rem}}@media (min-width:1700px){#content-container>div{justify-content:center}}"},{"filePath":"reference/github-actions/runner-configuration.css","content":""},{"filePath":"workspaces/access.css","content":""},{"filePath":"platform/workspaces/access.css","content":""},{"filePath":"reference/devbox-cli/desktop.css","content":""}],"page":{"pagePath":"integrations/nix","slug":"/integrations/nix","pageMetadata":{"title":"Nix","sidebarTitle":"Nix","description":"Share Nix build outputs across runners with nixcache and cache public packages on demand.","href":"/integrations/nix"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Share Nix build outputs across runners with nixcache and cache public packages on demand.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,tbody:`tbody`,td:`td`,th:`th`,thead:`thead`,tr:`tr`,..._provideComponents(),...props.components},{CodeBlock,Heading,Info,Step,Steps,Table,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Info)_missingMdxReference(`Info`,true);if(!Step)_missingMdxReference(`Step`,true);if(!Steps)_missingMdxReference(`Steps`,true);if(!Table)_missingMdxReference(`Table`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[_jsx(_components.code,{children:`nixcache`}),` is a local HTTP binary-cache proxy backed by Namespace blobstorage. It combines a local disk cache with shared storage, so a fresh runner can reuse cached Nix outputs without landing on the machine that built them.`]}),`\n`,_jsx(Info,{children:_jsxs(_components.p,{children:[`Nix caching is in `,_jsx(_components.strong,{children:`early access`}),`. `,_jsx(_components.a,{href:`mailto:support@namespace.so`,children:`Contact support`}),` to set up a cache namespace and the credentials your workflows need.`]})}),`\n`,_jsxs(_components.p,{children:[`The proxy supports Linux and macOS on amd64 and arm64. It works with an existing Nix installation and does not change where builds execute. You can also use it on a `,_jsx(_components.a,{href:`#remote-builders`,children:`remote Nix builder`}),`; configure each machine that needs to substitute or publish outputs.`]}),`\n`,_jsx(Heading,{level:`2`,id:`install-nixcache`,children:`Install nixcache`}),`\n`,_jsx(_components.p,{children:`Install the latest released binary:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -fsSL`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://public.namespaceblobs.com/nixcache/install.sh\`}),\_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` |`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` sh`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The installer verifies the archive’s SHA-256 checksum and installs to `,_jsx(_components.code,{children:`/.local/bin/nixcache`}),` without sudo by default. It requires `,_jsx(_components.code,{children:`curl`}),`, `,_jsx(_components.code,{children:`tar`}),`, `,_jsx(_components.code,{children:`sed`}),`, `,_jsx(_components.code,{children:`awk`}),`, and either `,_jsx(_components.code,{children:`sha256sum`}),` or `,_jsx(_components.code,{children:`shasum`}),`. It does not install Nix, modify Nix configuration, or start the proxy.`]}),`\n`,_jsx(Heading,{level:`2`,id:`start-the-proxy`,children:`Start the proxy`}),`\n`,_jsx(_components.p,{children:`After cache access is enabled for your workspace, start the proxy:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`10`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`10`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [ `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`-n`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:' \"${'}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`NSC_CACHE_PATH`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:-`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`}\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` ]; `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`then`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` cache_root`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$NSC_CACHE_PATH`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`elif`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` [ `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"$(`}),_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`uname`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -s`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`)\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` Darwin ]; `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`then`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` cache_root`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$HOME`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/Library/Caches\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`else`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` cache_root`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:'\"${'}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`XDG_CACHE_HOME`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`:-`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$HOME`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`/`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`cache`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`}\"`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`fi`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:``}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`/.local/bin/nixcache `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:`\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` -cache_dir`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$cache_root`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/nixcache\"`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`The command starts a background process and returns once the listener is ready. It prints the listener address, PID, and log path. The default address is `,_jsx(_components.code,{children:`http://127.0.0.1:18765\`}),\`.\`\]}),\`\\n\`,\_jsxs(_components.p,{children:[`The example prefers the `,_jsx(_components.a,{href:`/architecture/storage/cache-volumes`,children:`Cache Volume`}),` at `,_jsx(_components.code,{children:`NSC_CACHE_PATH`}),` to reuse local downloads across jobs. Without a volume, it uses the OS user cache directory: `,_jsx(_components.code,{children:`/Library/Caches`}),` on macOS, or `,_jsx(_components.code,{children:`XDG_CACHE_HOME`}),` with a fallback to `,_jsx(_components.code,{children:`/.cache`}),` on Linux. The examples below reuse this `,_jsx(_components.code,{children:`cache_root`}),` variable.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`-cache_dir`}),` selects a dedicated local directory for cached archives and staged uploads. Without it, the proxy uses temporary storage that is removed on clean shutdown. Shared blobstorage remains available to other runners regardless of the local directory.`]}),`\n`,_jsx(Heading,{level:`3`,id:`authentication`,children:`Authentication`}),`\n`,_jsxs(_components.p,{children:[`On Namespace instances, `,_jsx(_components.code,{children:`nixcache`}),` automatically uses the instance’s credentials.`]}),`\n`,_jsxs(_components.p,{children:[`On other machines, sign in with `,_jsx(_components.a,{href:`/reference/cli/login`,children:_jsx(_components.code,{children:`nsc login`})}),` before starting the proxy:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`nsc`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` login`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`The credentials must have access to the cache namespace.`}),`\n`,_jsx(Heading,{level:`2`,id:`configure-nix`,children:`Configure Nix`}),`\n`,_jsx(_components.p,{children:`Add these settings to your Nix configuration to route substitution through the proxy:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`ini`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`ini`,children:_jsxs(_components.code,{language:`ini`,numberOfLines:`2`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`substituters`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = http://127.0.0.1:18765\`})\]}),\`\\n\`,\_jsxs(\_components.span,{className:\`line\`,children:\[\_jsx(\_components.span,{style:{color:\`#CF222E\`,\\"--shiki-dark\\":\`#569CD6\`},children:\`require-sigs\`}),\_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = true`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Keep Nix’s standard `,_jsx(_components.code,{children:`cache.nixos.org-1`}),` trusted public key. Public packages retain their original signatures, so no additional key is required for the default public fallback.`]}),`\n`,_jsxs(_components.p,{children:[`For multi-user Nix, set these options in the daemon’s configuration, normally `,_jsx(_components.code,{children:`/etc/nix/nix.conf`}),`, and reload or restart the daemon as required by your Nix installation. The daemon must be able to reach the proxy’s loopback address. A proxy running inside a different container or network namespace is not reachable at the daemon’s `,_jsx(_components.code,{children:`127.0.0.1`}),`.`]}),`\n`,_jsxs(_components.p,{children:[`Use `,_jsx(_components.code,{children:`extra-substituters`}),` instead of `,_jsx(_components.code,{children:`substituters`}),` if you want to retain other configured caches. Keeping `,_jsx(_components.code,{children:`https://cache.nixos.org\`}),\` as a direct substituter lets Nix bypass the proxy, so those downloads may not populate the Namespace cache.`]}),`\n`,_jsx(_components.p,{children:`After configuration, ordinary Nix commands use the cache:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`nix`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` build`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` .#your-package`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Replace `,_jsx(_components.code,{children:`your-package`}),` with an output from your project. This example uses flakes and the `,_jsx(_components.code,{children:`nix`}),` command, which must be enabled in your Nix installation.`]}),`\n`,_jsx(Heading,{level:`2`,id:`public-cache-fallback`,children:`Public-cache fallback`}),`\n`,_jsxs(_components.p,{children:[`By default, `,_jsx(_components.code,{children:`nixcache`}),` falls back to `,_jsx(_components.code,{children:`https://cache.nixos.org\`}),\` for entries missing from Namespace blobstorage. It downloads archives into the local cache using parallel byte ranges and serves available bytes to Nix before the full download completes.`]}),`\n`,_jsxs(_components.p,{children:[`Choose how upstream entries are cached with `,_jsx(_components.code,{children:`-cache-upstream`}),`:`]}),`\n`,_jsxs(Table,{children:[_jsx(_components.thead,{children:_jsxs(_components.tr,{children:[_jsx(_components.th,{children:`Mode`}),_jsx(_components.th,{children:`Behavior`})]})}),_jsxs(_components.tbody,{children:[_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[_jsx(_components.code,{children:`persist`}),` (default)`]}),_jsx(_components.td,{children:`Fetch missing entries from the public upstream, cache archives locally, and publish entries to Namespace blobstorage in the background. Requires write access to populate shared storage.`})]}),_jsxs(_components.tr,{children:[_jsx(_components.td,{children:_jsx(_components.code,{children:`local-only`})}),_jsx(_components.td,{children:`Fetch missing entries from the public upstream and cache archives locally, without publishing fallback entries to blobstorage. Use this with read-only credentials.`})]}),_jsxs(_components.tr,{children:[_jsxs(_components.td,{children:[_jsx(_components.code,{children:`off`}),` or `,_jsx(_components.code,{children:`disabled`})]}),_jsx(_components.td,{children:`Disable public fallback. Continue serving local and blobstorage entries. Explicit uploads remain enabled.`})]})]})]}),`\n`,_jsx(_components.p,{children:`For example, restrict a consumer to entries already available in Namespace:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`3`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`3`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:``}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`/.local/bin/nixcache `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:`\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` -cache_dir`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$cache_root`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/nixcache\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -cache-upstream=off`})}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Namespace credentials are never sent to the public upstream.`}),`\n`,_jsxs(_components.p,{children:[`Fallback happens only on a blobstorage not-found response. Authentication failures, throttling, and storage outages do not trigger public fallback. Namespace credentials are still required in `,_jsx(_components.code,{children:`local-only`}),` mode.`]}),`\n`,_jsxs(_components.p,{children:[`In `,_jsx(_components.code,{children:`persist`}),` mode, the proxy publishes the archive before its original `,_jsx(_components.code,{children:`.narinfo`}),` metadata. It preserves Nix hashes and signatures, so no private signing key is needed to mirror public packages. Once publication finishes, another runner can fetch the entry from blobstorage even with fallback disabled.`]}),`\n`,_jsxs(_components.p,{children:[`Publication is asynchronous and best-effort. Failures are logged without interrupting the read. If a job must populate shared storage, allow publication to finish before stopping the proxy: a `,_jsx(_components.code,{children:`fallback entry stored`}),` log for a `,_jsx(_components.code,{children:`.narinfo`}),` path confirms that its archive and metadata were published. Stopping the proxy cancels pending publication.`]}),`\n`,_jsx(Heading,{level:`2`,id:`publish-your-own-builds`,children:`Publish your own builds`}),`\n`,_jsxs(_components.p,{children:[`Trusted CI needs cache write access and a Nix private signing key. Follow the `,_jsx(_components.a,{href:`#authentication`,children:`authentication instructions`}),`, then publish a built output and its dependencies using native `,_jsx(_components.code,{children:`nix copy`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:``}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`/.local/bin/nixcache `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:`\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:` -cache_dir`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$cache_root`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/nixcache-writer\"`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`nix`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` build`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` .#your-package`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`nix`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` copy`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --to`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'http://127.0.0.1:18765?secret-key=/run/secrets/cache-private.key'\`}),\_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` ./result`})}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Run the writer instead of the reader proxy on that machine, or assign separate loopback ports with `,_jsx(_components.code,{children:`-listen`}),` and update the URLs accordingly. Replace the signing-key path with a file provisioned by your CI secret manager.`]}),`\n`,_jsxs(_components.p,{children:[_jsx(_components.code,{children:`secret-key`}),` is a native Nix store URI setting. Nix reads the signing key locally; it is not sent to the proxy. No separate upload client is required.`]}),`\n`,_jsx(_components.p,{children:`Consumers of your signed outputs must add the corresponding public key to their Nix configuration:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`ini`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`ini`,children:_jsxs(_components.code,{language:`ini`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`extra-trusted-public-keys`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` = MY-CACHE:BASE64_PUBLIC_KEY`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Replace the placeholder with your cache’s public signing key. Keep `,_jsx(_components.code,{children:`require-sigs = true`}),` and retain any upstream public keys you use.`]}),`\n`,_jsx(Heading,{level:`3`,id:`isolate-untrusted-forks`,children:`Isolate untrusted forks`}),`\n`,_jsxs(_components.p,{children:[`Give fork jobs credentials with only namespace-scoped `,_jsx(_components.code,{children:`blobs`}),` read access. Trusted CI uses separate writer credentials and holds the private signing key. Support can help configure these permissions during early access.`]}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.code,{children:`-cache-upstream=local-only`}),` disables automatic fallback publication, not writes. Blobstorage enforces access permissions. Any process that can reach the proxy can use its credential’s permissions, so never expose a writer proxy, writer credential, private signing key, or writable trusted cache directory to untrusted jobs.`]})}),`\n`,_jsx(_components.p,{children:`Use a separate proxy and local cache directory for each trust boundary. Public signing keys can be shared with readers; private keys cannot.`}),`\n`,_jsx(Heading,{level:`2`,id:`operation-and-troubleshooting`,children:`Operation and troubleshooting`}),`\n`,_jsxs(_components.p,{children:[`Background logs are written to `,_jsx(_components.code,{children:`cache_dir/cacheproxy.log`}),` when `,_jsx(_components.code,{children:`-cache_dir`}),` is set. Use `,_jsx(_components.code,{children:`-log_file`}),` to choose another location, or `,_jsx(_components.code,{children:`-foreground`}),` to run under a process supervisor and log to the terminal. Logs include HTTP access and download or publication failures.`]}),`\n`,_jsxs(_components.p,{children:[`At startup, the proxy removes unfinished downloads and staged uploads while preserving completed local entries. Stop it with `,_jsx(_components.code,{children:`kill -TERM \u003cprinted-pid>`}),` during job cleanup. There is no local eviction policy yet: budget disk space for downloads and concurrent uploads, and remove old cache directories while the proxy is stopped.`]}),`\n`,_jsx(_components.p,{children:`Local cache entries are partitioned by storage endpoint, namespace, upstream URL, and credential scope. Token rotation can cause cold local reads; a persistent directory does not guarantee a local hit across credential changes.`}),`\n`,_jsx(Heading,{level:`2`,id:`remote-builders`,children:`Remote builders`}),`\n`,_jsxs(_components.p,{children:[`Namespace compute instances can also run as remote Nix builders using Nix’s `,_jsx(_components.a,{href:`https://nix.dev/manual/nix/2.18/advanced-topics/distributed-builds\`,children:\`distributed builds`}),` feature. Remote builders execute builds; `,_jsx(_components.code,{children:`nixcache`}),` stores and serves their outputs. You can use either independently or configure the cache on your remote builders as well.`]}),`\n`,_jsxs(_components.p,{children:[`The following steps prepare an instance with Nix and `,_jsx(_components.code,{children:`nixcache`}),` installed. Enable cache access for the workspace first, as described under `,_jsx(_components.a,{href:`#authentication`,children:`authentication`}),`.`]}),`\n`,_jsxs(Steps,{titleSize:`h3`,children:[_jsxs(Step,{title:`Create a bare compute instance`,id:`create-a-bare-compute-instance`,children:[_jsx(_components.p,{children:`Create a new compute instance with your SSH key:`}),_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`nsc`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` create`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --bare`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` --ssh_key`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` /.ssh/id_ed25519.pub`})]}),`\n`]})})}),_jsxs(_components.p,{children:[`You can use an existing SSH key or create a new one specifically for this purpose with `,_jsx(_components.code,{children:`ssh-keygen -t ed25519`}),`.`]}),_jsx(_components.p,{children:`Grab the instance ID from the output.`})]}),_jsxs(Step,{title:`Install Nix on the remote instance`,id:`install-nix-on-the-remote-instance`,children:[_jsx(_components.p,{children:`SSH into the instance and install Nix using the Determinate installer:`}),_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`ssh`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`@ssh.ord2.namespace.so`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"curl -fsSL https://install.determinate.systems/nix | sh -s -- install linux --determinate --init none --no-confirm\"`})]}),`\n`]})})}),_jsxs(_components.p,{children:[`Bare instances run as root and do not require `,_jsx(_components.code,{children:`sudo`}),`. With `,_jsx(_components.code,{children:`--init none`}),`, the installer leaves the Nix daemon stopped and may report a missing daemon socket during its self-test. Start it after configuring the cache below.`]})]}),_jsxs(Step,{title:`Install and start nixcache on the builder`,id:`install-and-start-nixcache-on-the-builder`,children:[_jsx(_components.p,{children:`Run the following from your client. The quoted heredoc keeps the environment variables on the remote instance, so the cache directory belongs to the builder rather than your client:`}),_jsx(CodeBlock,{filename:``,numberOfLines:`7`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`7`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`ssh`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`@ssh.ord2.namespace.so`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'bash -s'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c\u003c`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`'EOF'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`set -eu`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`curl -fsSL https://public.namespaceblobs.com/nixcache/install.sh | sh`})}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:'cache_root=\"${NSC_CACHE_PATH:-${XDG_CACHE_HOME:-$HOME/.cache}}\"'})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`/.local/bin/nixcache -cache_dir \"$cache_root/nixcache\"`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`EOF`})}),`\n`]})})}),_jsxs(_components.p,{children:[`This Linux example prefers the instance’s Cache Volume when available. The proxy uses the instance’s credentials and defaults to `,_jsx(_components.code,{children:`-cache-upstream=persist`}),` to `,_jsx(_components.a,{href:`#public-cache-fallback`,children:`publish public packages to shared storage`}),`.`]})]}),_jsxs(Step,{title:`Configure Nix on the builder`,id:`configure-nix-on-the-builder`,children:[_jsxs(_components.p,{children:[`Add a separate configuration file and include it from `,_jsx(_components.code,{children:`nix.custom.conf`}),`, which the Determinate installer reserves for user settings:`]}),_jsx(CodeBlock,{filename:``,numberOfLines:`10`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`10`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`ssh`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`@ssh.ord2.namespace.so`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'bash -s'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c\u003c`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`'EOF'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`set -eu`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`cat > /etc/nix/nixcache.conf \u003c\u003c'CONF'`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`substituters = http://127.0.0.1:18765\`})}),\`\\n\`,\_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`require-sigs = true`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`CONF`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`if ! grep -qxF '!include nixcache.conf' /etc/nix/nix.custom.conf; then`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` printf '\\\n!include nixcache.conf\\\n' >> /etc/nix/nix.custom.conf`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`fi`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`EOF`})}),`\n`]})})}),_jsxs(_components.p,{children:[`Keep the existing trusted public keys. Determinate also adds its own installer substituter; the default `,_jsx(_components.code,{children:`cache.nixos.org`}),` route now goes through the proxy.`]})]}),_jsxs(Step,{title:`Start the Nix daemon`,id:`start-the-nix-daemon`,children:[_jsx(_components.p,{children:`Start the daemon once on this fresh instance. Redirect its input and output so it remains running after SSH disconnects:`}),_jsx(CodeBlock,{filename:``,numberOfLines:`5`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`5`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`ssh`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`@ssh.ord2.namespace.so`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` 'bash -s'`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c\u003c`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`'EOF'`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`set -eu`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`nohup /nix/var/nix/profiles/default/bin/nix-daemon \\\`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` > /var/log/nix-daemon.log 2>\u00261 \u003c /dev/null \u0026`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`EOF`})}),`\n`]})})}),_jsx(_components.p,{children:`On an existing builder with a running daemon, restart that daemon after configuration changes instead of starting a second one.`})]}),_jsxs(Step,{title:`Test the installation`,id:`test-the-installation`,children:[_jsxs(_components.p,{children:[`Run a package on the builder. Nix uses the builder’s local proxy for substitution, which falls back to `,_jsx(_components.code,{children:`cache.nixos.org`}),` on a shared-cache miss:`]}),_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`ssh`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` \u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`@ssh.ord2.namespace.so`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` nix`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` run`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` nixpkgs#hello`})]}),`\n`]})})}),_jsx(_components.p,{children:`If the package is already in the builder’s Nix store, Nix does not need to fetch it again. Check the proxy’s access logs to see which requests reached the cache.`})]})]}),`\n`,_jsxs(_components.p,{children:[`Follow Nix’s distributed-build configuration to connect your client to this instance. Enable `,_jsx(_components.code,{children:`builders-use-substitutes = true`}),` on the client to let remote builders fetch available dependencies from their configured substituters instead of copying them from the client. The proxy must run on the builder: its `,_jsx(_components.code,{children:`127.0.0.1`}),` is separate from the client’s.`]}),`\n`,_jsxs(_components.p,{children:[`Building an output does not automatically publish it. Use the `,_jsx(_components.a,{href:`#publish-your-own-builds`,children:`signed publication instructions`}),` on the builder to share your own outputs with other machines.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Nix","sidebarTitle":"Nix","description":"Share Nix build outputs across runners with nixcache and cache public packages on demand.","href":"/integrations/nix"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Install nixcache","slug":"install-nixcache","depth":2,"children":[]},{"title":"Start the proxy","slug":"start-the-proxy","depth":2,"children":[{"title":"Authentication","slug":"authentication","depth":3,"children":[]}]},{"title":"Configure Nix","slug":"configure-nix","depth":2,"children":[]},{"title":"Public-cache fallback","slug":"public-cache-fallback","depth":2,"children":[]},{"title":"Publish your own builds","slug":"publish-your-own-builds","depth":2,"children":[{"title":"Isolate untrusted forks","slug":"isolate-untrusted-forks","depth":3,"children":[]}]},{"title":"Operation and troubleshooting","slug":"operation-and-troubleshooting","depth":2,"children":[]},{"title":"Remote builders","slug":"remote-builders","depth":2,"children":[{"title":"Create a bare compute instance","slug":"create-a-bare-compute-instance","depth":3,"children":[]},{"title":"Install Nix on the remote instance","slug":"install-nix-on-the-remote-instance","depth":3,"children":[]},{"title":"Install and start nixcache on the builder","slug":"install-and-start-nixcache-on-the-builder","depth":3,"children":[]},{"title":"Configure Nix on the builder","slug":"configure-nix-on-the-builder","depth":3,"children":[]},{"title":"Start the Nix daemon","slug":"start-the-nix-daemon","depth":3,"children":[]},{"title":"Test the installation","slug":"test-the-installation","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/namespace-labs/fa018fe02fd436c8/navigation.js","/docs/_mintlify/custom/namespace-labs/4276600b7cb636ff/legacy-anchor-redirects.js"],"subdomain":"namespace-labs","siteName":"Namespace Documentation","title":"Nix - Namespace Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-09-14T14:34:59.213Z","gitLastModified":"2026-09-15T08:26:41.000Z","originalFileLocation":"integrations/nix.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Share Nix build outputs across runners with nixcache and cache public packages on demand.\">\u003cmeta data-mint-head name=\"application-name\" content=\"Namespace Documentation\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Nix - Namespace Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Share Nix build outputs across runners with nixcache and cache public packages on demand.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Namespace Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://namespace.so/docs/integrations/nix\\">\\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://namespace-labs.mintlify.app/\_mintlify/api/og/v2?division=Integrations\\u0026amp;title=Nix\\u0026amp;description=Share+Nix+build+outputs+across+runners+with+nixcache+and+cache+public+packages+on+demand.\\u0026amp;theme=1f89d53762a6d5304d1c63c4\\u0026amp;signature=6ace923387e718f0024bea8c6497b68d3a00dd51377fc26af297ebf7f603ef37\\">\\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Nix - Namespace Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Share Nix build outputs across runners with nixcache and cache public packages on demand.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://namespace-labs.mintlify.app/\_mintlify/api/og/v2?division=Integrations\\u0026amp;title=Nix\\u0026amp;description=Share+Nix+build+outputs+across+runners+with+nixcache+and+cache+public+packages+on+demand.\\u0026amp;theme=1f89d53762a6d5304d1c63c4\\u0026amp;signature=6ace923387e718f0024bea8c6497b68d3a00dd51377fc26af297ebf7f603ef37\\">\\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/namespace-labs/kZKeJ4zhJEuE6_kI/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Namespace Documentation\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#1C32FF\">\u003clink data-mint-head rel=\"canonical\" href=\"https://namespace.so/docs/integrations/nix\\">\\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/integrations/nix.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\\",\\"@graph\\":\[{\\"@type\\":\\"Organization\\",\\"@id\\":\\"https://namespace.so/#organization\\",\\"name\\":\\"Namespace Documentation\",\"url\":\"https://namespace.so\\",\\"logo\\":{\\"@type\\":\\"ImageObject\\",\\"url\\":\\"https://mintcdn.com/namespace-labs/qOJQ7kaWRgoS8lyv/logo-light.svg?fit=max\\u0026auto=format\\u0026n=qOJQ7kaWRgoS8lyv\\u0026q=85\\u0026s=6827b0c81c335badc1cef13b83383e1d\\"}},{\\"@type\\":\\"WebSite\\",\\"@id\\":\\"https://namespace.so/docs#website\\",\\"name\\":\\"Namespace Documentation\",\"url\":\"https://namespace.so/docs\\",\\"publisher\\":{\\"@id\\":\\"https://namespace.so/#organization\\"}},{\\"@type\\":\\"WebPage\\",\\"@id\\":\\"https://namespace.so/docs/integrations/nix#webpage\\",\\"url\\":\\"https://namespace.so/docs/integrations/nix\\",\\"name\\":\\"Nix\\",\\"description\\":\\"Share Nix build outputs across runners with nixcache and cache public packages on demand.\",\"dateModified\":\"2026-09-15T08:26:41.000Z\",\"isPartOf\":{\"@id\":\"https://namespace.so/docs#website\\"},\\"breadcrumb\\":{\\"@id\\":\\"https://namespace.so/docs/integrations/nix#breadcrumb\\"}},{\\"@type\\":\\"BreadcrumbList\\",\\"@id\\":\\"https://namespace.so/docs/integrations/nix#breadcrumb\\",\\"itemListElement\\":\[{\\"@type\\":\\"ListItem\\",\\"position\\":1,\\"name\\":\\"Integrations\\",\\"item\\":\\"https://namespace.so/docs/integrations/turborepo\\"},{\\"@type\\":\\"ListItem\\",\\"position\\":2,\\"name\\":\\"Nix\\",\\"item\\":\\"https://namespace.so/docs/integrations/nix\\"}\]},{\\"@type\\":\[\\"Article\\",\\"TechArticle\\"\],\\"@id\\":\\"https://namespace.so/docs/integrations/nix#article\\",\\"headline\\":\\"Nix\\",\\"name\\":\\"Nix\\",\\"description\\":\\"Share Nix build outputs across runners with nixcache and cache public packages on demand.\",\"url\":\"https://namespace.so/docs/integrations/nix\\",\\"mainEntityOfPage\\":{\\"@id\\":\\"https://namespace.so/docs/integrations/nix#webpage\\"},\\"dateModified\\":\\"2026-09-15T08:26:41.000Z\\",\\"publisher\\":{\\"@id\\":\\"https://namespace.so/#organization\\"},\\"isPartOf\\":{\\"@id\\":\\"https://namespace.so/docs#website\\"}}\]}\\u003c/script>\\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\\",\\"@type\\":\\"WebSite\\",\\"name\\":\\"Namespace Documentation\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\\"}}\\u003c/script>","siteName":"Namespace Documentation","nav":{"global":{"anchors":[{"anchor":"Changelog","icon":"history","href":"https://namespace.so/changelog"},{"anchor":"Trust Center (SOC2)","icon":"shield-check","href":"https://trust.namespace.so/"},{"anchor":"Status","icon":"activity","href":"https://namespace-status.com/"},{"anchor":"Support","icon":"message-circle","href":"https://namespace.so/support"}\]},"products":\[{"product":"Products","description":"Turnkey products built on the Namespace platform","tabs":[{"tab":"Documentation","icon":"book-open","pages":[{"title":"Documentation","href":""}]},{"tab":"Integrations","icon":"blocks","pages":[{"group":"Integrations","icon":"blocks","pages":[{"title":"Turborepo caching","sidebarTitle":"Turborepo","href":"/integrations/turborepo"},{"title":"Playwright","href":"/integrations/playwright"},{"title":"Android Emulators","href":"/integrations/android-emulators"},{"title":"Gradle integration","sidebarTitle":"Gradle","href":"/integrations/gradle"},{"title":"sccache integration","sidebarTitle":"sccache","href":"/integrations/sccache"},{"title":"Optimizing Docker Build Performance in Circle CI","sidebarTitle":"CircleCI","href":"/solutions/circle-ci/docker-builds"},{"title":"Pants integration","sidebarTitle":"Pants","href":"/integrations/pants"},{"title":"Moonrepo support","sidebarTitle":"Moonrepo","description":null,"href":"/integrations/moonrepo"},{"title":"Nix","sidebarTitle":"Nix","href":"/integrations/nix"},{"title":"Go","sidebarTitle":"Go","description":"Cache Go modules and build outputs on Cache Volumes, with early-access remote caching for incremental builds across machines.","href":"/integrations/go"},{"title":"Git Checkouts","href":"/integrations/git-checkouts"},{"title":"Docker Images","href":"/integrations/docker-images"},{"title":"Tailscale","href":"/integrations/tailscale"},{"title":"Integrating any framework","sidebarTitle":"Any framework","href":"/integrations/any-framework"}]}]},{"tab":"CLI","icon":"square-terminal","pages":[{"title":"CLI","href":"/reference/cli"}]},{"tab":"SDK","icon":"braces","pages":[{"title":"SDK","href":"/reference/sdk"}]},{"tab":"MCP","icon":"plug","pages":[{"title":"MCP","href":"/reference/mcp"}]}]},{"product":"Platform","description":"Lower-level primitives to build your own","pages":[{"title":"Platform","href":"/platform"}]}]},"title":"Nix - Namespace Documentation","buildId":"dpl_GvhK4qVXq51DpfYJLCtPpYNN4YHN","deploymentId":"dpl_GvhK4qVXq51DpfYJLCtPpYNN4YHN","dynamics":[],"chunks":[]}