Skip to content

ollama

Repo box/github.com/opencharly/pod-ollama:v2026.328.0727

GPU-agnostic Ollama LLM inference server on port 11434 Installs the Ollama binary and runs ollama serve as a custom supervisord service that listens on 0.0.0.0:11434 (no systemd). Two install paths, one resulting layout (/usr/bin/ollama plus the backend libraries under /usr/lib/ollama): on a distro that PACKAGES ollama the package is installed and the package manager owns the version; everywhere else the upstream release tarball is extracted to /usr at the version the var OLLAMA_VERSION selects. That var is PINNED to a release tag and must stay one: the download cache is content-addressed by the sha256 of the URL, so a latest URL would hash to one key forever and serve the first tarball it ever fetched, long after upstream moved on. The candy declares NO GPU dependency — a GPU backend is an IMAGE-level composition choice (compose ollama-cuda or ollama-rocm). What that buys differs by install path, and the difference is worth stating rather than averaging: on a PACKAGED distro the base package is genuinely CPU-only at 75 MiB and a backend is strictly opt-in, which is what keeps this layer small; on the TARBALL path the single upstream archive already contains the CUDA backend, so a tarball consumer pays for it whether or not any box composes ollama-cuda. Pulled models persist under the ~/.ollama models volume. The running service exposes the Ollama HTTP API (e.g. /api/tags) so any composing box can serve and query local models. The companion plugin candy plugin-ollama adds the charly ollama management CLI against a deployed server. The service itself runs a charly-owned wrapper: it pulls the OLLAMA_PULL_MODELS defaults and gates the start on GPU readiness, so a start under VRAM pressure fails loudly (supervisord retries) instead of silently running a CPU-only server on a GPU pod — ollama serve probes the GPU exactly once, at startup.

  • ollama

This candy’s plan: — the runnable spec charly check executes against a live deployment. check: steps are idempotent probes; run: steps change state.

Intent Step
run install the upstream ollama release tarball on distros that ship no ollama package (var OLLAMA_VERSION)
check the ollama binary is installed at /usr/bin/ollama
run write the charly-owned ollama server wrapper
check the ollama server wrapper is installed at /opt/ollama/start-ollama.sh
check the installed ollama binary reports the release this candy pins (var OLLAMA_VERSION)
check the running ollama service answers the model-tags API with HTTP 200 on port 11434
check the ollama CLI reports an “ollama version” string
check the ollama CLI lists models against the live service with exit 0
check charly ollama help exits 0 and prints the plugin usage, proving the compiled-in command:ollama plugin registers and dispatches
check charly ollama version reports the server version over the published port, proving a live API round-trip against the deployed server
check charly ollama list prints the model table header over the published port, proving the list API path against the deployed server
check the supervised ollama server runs the charly wrapper, not ollama serve directly
check the wrapper pulls a declared model and reports every declared model present
check the GPU readiness gate refuses to start the server when no GPU has the required free memory, and names the reason
agent-check models pulled via ollama pull are stored under the ~/.ollama models volume and survive a service restart