{
  "@context": "https://schema.org",
  "@type": "WebPage",
  "name": "Run Ollama on Edge | Self-host open LLMs",
  "headline": "Run Ollama on Edge | Self-host open LLMs",
  "description": "Run Ollama on Edge CPU VMs today: quantised Llama, Qwen and Gemma models behind an OpenAI-compatible API, weights cached in storage. GPU instances coming soon.",
  "url": "https://edge.network/solutions/ollama",
  "image": "https://edge.network/og/solutions__ollama.png",
  "inLanguage": "en",
  "publisher": {
    "@type": "Organization",
    "name": "Edge Network",
    "url": "https://edge.network",
    "logo": "https://edge.network/favicon.svg"
  },
  "isPartOf": {
    "@type": "WebSite",
    "name": "Edge Network",
    "url": "https://edge.network"
  },
  "breadcrumb": {
    "@type": "BreadcrumbList",
    "itemListElement": [
      {
        "@type": "ListItem",
        "position": 1,
        "name": "Home",
        "item": "https://edge.network"
      },
      {
        "@type": "ListItem",
        "position": 2,
        "name": "Solutions",
        "item": "https://edge.network/solutions"
      },
      {
        "@type": "ListItem",
        "position": 3,
        "name": "Ollama",
        "item": "https://edge.network/solutions/ollama"
      }
    ]
  },
  "section": "solutions",
  "articleBody": "For Ollama\n\n Ollama on Edge, open models on your own VM\n\n Pull a quantised Llama, Qwen or Gemma model onto a CPU VM and serve it through Ollama&#x27;s OpenAI-compatible API. Prompts stay on your infrastructure, weights stay in your bucket, and there&#x27;s no per-token bill. Deploy a VM See AI infrastructure Runs on CPU VMs today. GPU instances are coming soon, and the waitlist is open.\n\n Why Ollama on Edge\n\n An OpenAI-style API, with your data and your costs under control \n\n Ollama makes open models easy to run. On an Edge CPU VM it&#x27;s a practical fit for small quantised models, internal tools and anything that shouldn&#x27;t leave your network. GPU instances are coming soon Edge GPU instances aren&#x27;t available yet. Until they launch, Ollama runs on CPU VMs, which suits quantised models up to about 8B parameters at modest speed. Larger models and high-volume serving will need a GPU instance. Join the GPU waitlist \n\n Quantised models on CPU\n\n 1B–8B models at Q4 run on an 8 vCPU VM. A good fit for internal tools, agents, classification and team-scale RAG. \n One binary, many models\n\n ollama pull llama3.2, qwen2.5, gemma3 or phi4-mini, then choose the model per request. Embedding models too. \n OpenAI-compatible API\n\n Point the OpenAI SDK at https://ai.acme.com/v1 and your code runs unchanged: chat, completions and embeddings. \n Weights cached in storage\n\n Sync the models directory to Edge Storage once. A new VM pulls from your bucket with zero egress, not from the registry. \n Prompts stay private\n\n Customer prompts and responses never leave your VM. Useful for regulated data and anything under NDA. \n No per-token bill\n\n Hosted APIs charge per million tokens. A VM is a fixed hourly price, however much it generates. \n Reference architecture\n\n Ollama behind a key, models cached in a bucket \n\n One CPU VM runs Ollama behind Nginx, which checks an API key. Model blobs are cached in a bucket, so a replacement VM is serving again without re-downloading from the registry. AI agent Your app and agents\n\n OpenAI SDK, baseURL /v1\n\n External n8n, Open WebUI\n\n same endpoint, own keys\n\n HTTPS Edge DNS ai.acme.com\n\n anycast DNS\n\n Edge CDN TLS in front of /v1\n\n completions bypass the cache\n\n Bearer key Edge Compute ollama serve :11434\n\n s-8vcpu-16gb, Nginx key check\n\n llama3.2:3b nomic-embed S3 sync Edge Storage llm-weights\n\n ollama/ blobs and manifests\n\n 2.0 GB Compute Runs Ollama and Nginx on an 8 vCPU, 16 GiB VM: enough for quantised models up to about 8B.\n\n GPU Compute Coming soon. GPU instances for larger models and higher throughput; join the waitlist.\n\n Storage Caches model blobs so new or rebuilt VMs pull weights from your bucket, egress-free.\n\n CDN Terminates TLS and adds DDoS protection in front of the API; completions bypass the cache.\n\n DNS Anycast DNS for ai.acme.com.\n\n Shield Scores the public chat form in front of your model, so bots don&#x27;t burn CPU time.\n\n Deploy\n\n Ollama behind an API key in five steps \n\n Ollama has no authentication of its own, so it listens on localhost and Nginx checks a key in front of it. ~/llm $ edge compute create --name llm \\ \n\n --size s-8vcpu-16gb --disk 160 \\\n\n --image ubuntu-24 --region london \\\n\n --script ollama-setup\n\n ✓ vm-4e19b7 running, 64.34.86.77\n\n $ ollama pull llama3.2:3b \n\n ✓ llama3.2:3b, 2.0 GB, Q4_K_M\n\n $ edge storage sync /var/lib/ollama/models \\ \n\n llm-weights/ollama/\n\n ✓ weights cached in Edge Storage\n\n Per-token fees $0 Ol ai.acme.com Running Runtime ollama, CPU Model llama3.2:3b, Q4_K_M 01 Write a bootstrap script\n\n Installs Ollama and the Edge CLI, keeps Ollama on localhost and stores models where the sync step expects them.\n\n ollama-setup.sh Copy #!/bin/bash\nset -e\ncurl -fsSL https://ollama.com/install.sh | sh\ncurl -fsSL https://edge.network/install.sh | sh\nmkdir -p /var/lib/ollama/models\nchown -R ollama:ollama /var/lib/ollama\nmkdir -p /etc/systemd/system/ollama.service.d\ncat > /etc/systemd/system/ollama.service.d/edge.conf <<&#x27;EOF&#x27;\n[Service]\nEnvironment=\"OLLAMA_HOST=127.0.0.1:11434\"\nEnvironment=\"OLLAMA_MODELS=/var/lib/ollama/models\"\nEnvironment=\"OLLAMA_KEEP_ALIVE=24h\"\nEOF\nsystemctl daemon-reload && systemctl restart ollama\napt-get install -y nginx \n 02 Create the VM\n\n 8 vCPU and 16 GiB leave room for an 8B Q4 model plus an embedding model. --disk 160 gives space for several models.\n\n shell Copy $ edge compute scripts create --name ollama-setup \\\n --file ollama-setup.sh\n$ edge compute create --name llm --size s-8vcpu-16gb --disk 160 \\\n --image ubuntu-24 --region london --script ollama-setup \n 03 Pull models and cache them\n\n Pull once, then sync to your bucket. A replacement VM syncs back before Ollama starts.\n\n shell Copy $ ollama pull llama3.2:3b\n$ ollama pull nomic-embed-text\n$ edge storage sync /var/lib/ollama/models llm-weights/ollama/\n\n# on a new VM, before starting Ollama\n$ edge storage sync llm-weights/ollama/ /var/lib/ollama/models \n 04 Check the key in Nginx\n\n OpenAI SDKs send the key as a Bearer token. Buffering is off so tokens stream as they&#x27;re generated.\n\n /etc/nginx/sites-enabled/ollama Copy server {\n listen 443 ssl;\n server_name ai.acme.com;\n ssl_certificate /etc/ssl/origin.pem; # origin certificate\n ssl_certificate_key /etc/ssl/origin.key;\n\n location /v1/ {\n if ($http_authorization != \"Bearer sk-acme-change-me\") {\n return 401;\n }\n proxy_pass http://127.0.0.1:11434;\n proxy_buffering off;\n proxy_read_timeout 300s;\n }\n} \n 05 Put the endpoint behind the CDN\n\n Add a bypassCache rule for /v1/** in the deployment&#x27;s configuration, then call it like any OpenAI endpoint.\n\n shell Copy $ edge cdn create --name ai\n$ edge cdn domains add cdn-a1b2c3 \\\n --domain ai.acme.com --origin https://<vm-ip>\n\n$ curl https://ai.acme.com/v1/chat/completions \\\n -H \"Authorization: Bearer $OLLAMA_KEY\" \\\n -H \"Content-Type: application/json\" \\\n -d &#x27;{\"model\": \"llama3.2:3b\",\n \"messages\": [{\"role\": \"user\", \"content\": \"Hi\"}]}&#x27; \n Prefer to hand it off? Give the job to your AI agent or have our engineers do it .\n\n What it costs\n\n A fixed price for your own model endpoint \n\n No GPU instance is priced here because none is available yet. This is an 8 vCPU VM, priced from the published per-resource rates, plus the bucket that holds your weights. A fixed hourly price, whatever you generate \n Weights pulled from your bucket with zero egress \n Move to a GPU instance when they launch \n See compute pricing Estimated monthly bill on Edge\n\n Team assistant, llama3.2:3b on 8 vCPU, weights cached\n\n USD Compute (vCPU) $23.36 8 vCPU × $0.004/hr × 730 hrs \n Compute (memory) $29.90 16 GiB × $0.00256/GiB-hr × 730 hrs \n Compute (disk) $11.84 160 GiB NVMe × $0.074/GiB-mo \n Storage $0.30 25 GB of model weights, first 5 GB free \n CDN $0.00 API traffic, inside the 500k free requests \n DNS $0.00 Zone and records for ai.acme.com \n Egress $0.00 \n Total $65.40 FAQ\n\n Models, CPUs and securing the API \n\n Something else? Ask an engineer . Can Ollama really run without a GPU? Yes. Ollama runs on CPU out of the box. Small quantised models (1B–3B at Q4) are usable for interactive work; 7B–8B models run, but slower. Expect single-digit to low-double-digit tokens per second, not hosted-API speeds. Which model should I start with? llama3.2:3b or qwen2.5:3b for chat and tool use, a 7B–8B model at Q4 if you need better answers and can accept slower output, and nomic-embed-text for embeddings. When will GPU instances be available? GPU instances are coming soon. Join the waitlist at /compute/gpus to hear first. If you need GPU capacity now, contact us: we may be able to arrange early access or an interim option. How does this compare to OpenAI or other hosted APIs? Your prompts stay on your infrastructure and the price doesn&#x27;t scale with tokens. The trade-off: small open models on CPU are slower and less capable than frontier hosted models, so pick them for tasks they do well. How do I secure the API? Ollama has no built-in authentication, so never expose port 11434. Keep OLLAMA_HOST on 127.0.0.1, check a key in Nginx as in...",
  "headings": [
    {
      "level": 1,
      "text": "Ollama on Edge, open models on your own VM"
    },
    {
      "level": 3,
      "text": "Quantised models on CPU"
    },
    {
      "level": 3,
      "text": "One binary, many models"
    },
    {
      "level": 3,
      "text": "OpenAI-compatible API"
    },
    {
      "level": 3,
      "text": "Weights cached in storage"
    },
    {
      "level": 3,
      "text": "Prompts stay private"
    },
    {
      "level": 3,
      "text": "No per-token bill"
    },
    {
      "level": 3,
      "text": "Write a bootstrap script"
    },
    {
      "level": 3,
      "text": "Create the VM"
    },
    {
      "level": 3,
      "text": "Pull models and cache them"
    },
    {
      "level": 3,
      "text": "Check the key in Nginx"
    },
    {
      "level": 3,
      "text": "Put the endpoint behind the CDN"
    },
    {
      "level": 2,
      "text": "Run open models on your terms"
    }
  ],
  "relatedLinks": [
    {
      "@type": "WebPage",
      "name": "Network",
      "url": "https://edge.network/network"
    },
    {
      "@type": "WebPage",
      "name": "Pricing",
      "url": "https://edge.network/pricing"
    },
    {
      "@type": "WebPage",
      "name": "Docs",
      "url": "https://edge.network/docs"
    },
    {
      "@type": "WebPage",
      "name": "Sign in",
      "url": "https://edge.network/console/access"
    },
    {
      "@type": "WebPage",
      "name": "Solutions",
      "url": "https://edge.network/solutions"
    },
    {
      "@type": "WebPage",
      "name": "Stacks",
      "url": "https://edge.network/solutions/stacks"
    },
    {
      "@type": "WebPage",
      "name": "See AI infrastructure",
      "url": "https://edge.network/solutions/ai"
    },
    {
      "@type": "WebPage",
      "name": "Join the GPU waitlist",
      "url": "https://edge.network/compute/gpus"
    },
    {
      "@type": "WebPage",
      "name": "Compute",
      "url": "https://edge.network/compute"
    },
    {
      "@type": "WebPage",
      "name": "Storage",
      "url": "https://edge.network/storage"
    },
    {
      "@type": "WebPage",
      "name": "CDN",
      "url": "https://edge.network/cdn"
    },
    {
      "@type": "WebPage",
      "name": "DNS",
      "url": "https://edge.network/dns"
    },
    {
      "@type": "WebPage",
      "name": "Shield",
      "url": "https://edge.network/shield"
    },
    {
      "@type": "WebPage",
      "name": "Give the job to your AI agent",
      "url": "https://edge.network/solutions/agentic-development"
    },
    {
      "@type": "WebPage",
      "name": "have our engineers do it",
      "url": "https://edge.network/solutions/expert-services"
    },
    {
      "@type": "WebPage",
      "name": "See compute pricing",
      "url": "https://edge.network/compute/pricing"
    },
    {
      "@type": "WebPage",
      "name": "Ask an engineer",
      "url": "https://edge.network/contact"
    },
    {
      "@type": "WebPage",
      "name": "Assist",
      "url": "https://edge.network/assist"
    },
    {
      "@type": "WebPage",
      "name": "Pulse",
      "url": "https://edge.network/pulse"
    },
    {
      "@type": "WebPage",
      "name": "Agent API &amp; MCP",
      "url": "https://edge.network/docs/agent"
    },
    {
      "@type": "WebPage",
      "name": "Academy",
      "url": "https://edge.network/academy"
    },
    {
      "@type": "WebPage",
      "name": "Case Studies",
      "url": "https://edge.network/case-studies"
    },
    {
      "@type": "WebPage",
      "name": "Releases",
      "url": "https://edge.network/releases"
    },
    {
      "@type": "WebPage",
      "name": "Roadmap",
      "url": "https://edge.network/roadmap"
    },
    {
      "@type": "WebPage",
      "name": "Status",
      "url": "https://edge.network/status"
    },
    {
      "@type": "WebPage",
      "name": "About",
      "url": "https://edge.network/about"
    },
    {
      "@type": "WebPage",
      "name": "Environment",
      "url": "https://edge.network/environment"
    },
    {
      "@type": "WebPage",
      "name": "Latest",
      "url": "https://edge.network/latest"
    },
    {
      "@type": "WebPage",
      "name": "Blog",
      "url": "https://edge.network/blog"
    },
    {
      "@type": "WebPage",
      "name": "Careers",
      "url": "https://edge.network/careers"
    }
  ],
  "alternateFormats": [
    {
      "@type": "MediaObject",
      "contentType": "text/html",
      "url": "https://edge.network/solutions/ollama",
      "name": "HTML version"
    }
  ],
  "dateModified": "2026-11-23T02:00:49.420Z"
}