Skip to Content
DocumentationApp CatalogCompanion Apps🌌 Tools Cache Mount

🌌 Tools Cache Mount

Share caches across your machines. Host-side shell tooling that NFS-mounts shared caches β€” Docker, Ollama, npm, Hugging Face β€” across the machines on your Tailscale, VPN, or LAN.

Install & availability

The Hub app is available, but it is only a status page. Install it from the Companion Hub App Store. The tooling that does the work isn’t publicly available yet β€” see the status note below.

Hub App StoreSearch Tools Cache Mount β†’ Install
Container internal port80
Minimum Hub version0.2.27
Architecturelinux/amd64 and linux/arm64 (multi-arch)
State / envNone β€” the container holds no state and takes no configuration

Overview

Tools Cache Mount is host-side shell tooling, not a Hub service. Its install scripts run on each of your machines and NFS-mount shared cache directories β€” Docker BuildKit caches, Ollama models, npm, Hugging Face β€” from a central NFS server reachable over your Tailscale, VPN, or LAN. Once mounted and pointed-to, every machine reuses the same downloaded models and build caches instead of fetching its own copy.

Installing the Hub app does not mount anything. The container is a static status / reference page describing the tooling. The actual mounting is done by running the install scripts on each client host. This page documents the real workflow.

Status: developer preview. You can’t install the tooling yet. The scripts have no public download, and their source repository is private, so you can run them only if Companion Intelligence gives you access. To ask about access or follow progress, join the DiscordΒ . The Hub container doesn’t include the scripts, and the Hub status page tells you to git clone the private repository, so the steps below need that access.

Current capabilities

What Tools Cache Mount provides today:

  • Per-host install scripts (linux_install.sh, macos_install.sh) that set up NFS mounts of shared caches
  • Sharing of Docker (BuildKit type=local), Ollama models, npm, and Hugging Face caches
  • Auto-mount on boot via fstab _netdev (Linux) or a launchd retry timer (macOS)
  • A status / reference page served by the Hub container

You must provide the NFS server. No server ships with this app. You need an NFS server on your network exporting /srv/cache/<name> directories; the client scripts mount from it.

How it actually works

  1. Stand up an NFS server (your responsibility) exporting /srv/cache/<name> for each cache you want to share (e.g. docker, ollama, npm, huggingface).
  2. Create cache-mounts.conf on each client host by copying cache-mounts.conf.example, and set CACHE_SERVER to that NFS server.
  3. Run the install script on each client (linux_install.sh or macos_install.sh). It configures the NFS mounts and auto-mount.
  4. Re-point your tools at the mounted caches β€” mounting alone changes nothing.

The same four steps, as the data path from your NFS server to each tool on a client host:

Default cache layout

CacheServer exportLinux mountmacOS mount
docker/srv/cache/docker/mnt/cache/docker/Volumes/cache-docker
ollama/srv/cache/ollama/mnt/cache/ollama/Volumes/cache-ollama
npm/srv/cache/npm/mnt/cache/npm/Volumes/cache-npm
huggingface/srv/cache/huggingface/mnt/cache/huggingface/Volumes/cache-huggingface

Configuration

The scripts read cache-mounts.conf from the repository root, whichever directory you run them from. Set CACHE_MOUNTS_CONFIG=/path/to/conf to use a different file.

VariableDefaultPurpose
CACHE_SERVERnoneHostname or IP of the NFS server, reachable on your VPN or LAN. Required.
CACHE_NAMESdocker ollama npm huggingfaceCaches to mount, separated by spaces or commas
CACHE_EXPORT_BASE/srv/cacheExport root on the server
CACHE_EXPORT_<NAME>, CACHE_MOUNT_<NAME>derivedPer-cache overrides, for example CACHE_EXPORT_HUGGINGFACE and CACHE_MOUNT_HUGGINGFACE

Auto-mount details

Auto-mountLinuxmacOS
Install scriptlinux_install.shmacos_install.sh
MechanismAn fstab entry with _netdev (fstab, not a systemd automount unit)A launchd job that retries every ~5 minutes to (re)establish the mount
Mounts whenOn boot, once the network is upAt each retry, until the mount is established
NeedsThe NFS server reachable once networking is upPasswordless sudo to run the mount
NFS clientnfs-common on Ubuntu and Debian. The install script installs it with apt-get.Built in
How each install script keeps the share mounted after a reboot.

On Linux, linux_install.sh backs up /etc/fstab to /etc/fstab.cache-mounts.bak.<timestamp>, adds the entries, and mounts now. Rerun it after you change the configuration, because it writes the resolved server and export paths into /etc/fstab. To mount or unmount by hand, use linux_mount.sh, linux_unmount.sh, macos_mount.sh, or macos_unmount.sh.

Re-pointing tools (required)

Mounting a cache does nothing until each tool is told to use it:

ToolWhat to set
Ollamaexport OLLAMA_MODELS=/mnt/cache/ollama (Linux) or /Volumes/cache-ollama (macOS)
Hugging Faceexport HF_HOME=/mnt/cache/huggingface (Linux) or /Volumes/cache-huggingface (macOS)
npmnpm config set cache /mnt/cache/npm
DockerBuildKit type=local cache sharing: docker buildx build --cache-to type=local,dest=/mnt/cache/docker/buildkit --cache-from type=local,src=/mnt/cache/docker/buildkit …

Docker caching here is BuildKit type=local cache sharing, not Docker image-layer caching. You opt in per build with BuildKit cache flags pointing at the shared local cache directory. For real image-layer caching, the repository’s Docker cache notes describe running a registry pull-through proxy on the cache server as an optional upgrade.

Use Cases

  • Download a model once and share it across every machine on your Tailnet
  • Share a BuildKit local cache so CI/build hosts don’t rebuild identical layers
  • Keep npm and Hugging Face caches consistent across a small fleet

Setup

Provide an NFS server

Stand up an NFS server on your Tailscale/VPN/LAN exporting /srv/cache/<name> for each cache you want to share. (No server ships with this app.)

Create cache-mounts.conf

On each client host, copy cache-mounts.conf.example to cache-mounts.conf and set CACHE_SERVER to your NFS server. Set CACHE_NAMES if you don’t want all four caches.

Run the install script

Run linux_install.sh (Linux) or macos_install.sh (macOS) on each client. This sets up the NFS mounts and auto-mount (fstab _netdev on Linux; a launchd retry on macOS that needs passwordless sudo).

Re-point your tools

Set OLLAMA_MODELS, HF_HOME, npm config set cache …, and use BuildKit type=local cache sharing for Docker so the tools actually use the mounted caches.

Troubleshooting

Installed the Hub app but nothing is shared The Hub container is only a status/reference page. Run the install scripts on each host to actually mount the caches.

Tools still download their own copies Mounting isn’t enough β€” re-point each tool (OLLAMA_MODELS, HF_HOME, npm cache, BuildKit type=local).

Mount doesn’t come back after reboot (macOS) The launchd retry needs passwordless sudo to run the mount. Verify the sudoers entry, then wait for the next ~5-minute retry.

Mount missing on Linux boot Confirm the fstab entry includes _netdev and the NFS server is reachable once networking is up.

Last updated on