From 771bc3688c7c5d24f74371bf568d663c19c6066f Mon Sep 17 00:00:00 2001 From: Cathie Integra Date: Sat, 23 May 2026 09:41:12 +0200 Subject: [PATCH] Docker: Tune Ollama defaults: flash-attention on, telemetry opt-outs --- compose.nvidia.yaml | 9 ++++++--- compose.yaml | 9 ++++++--- setup/docker/arm64/compose.yaml | 9 ++++++--- setup/docker/compose.yaml | 9 ++++++--- setup/docker/nvidia/compose.yaml | 9 ++++++--- 5 files changed, 30 insertions(+), 15 deletions(-) diff --git a/compose.nvidia.yaml b/compose.nvidia.yaml index 1251a14d8..7b2776e46 100644 --- a/compose.nvidia.yaml +++ b/compose.nvidia.yaml @@ -202,12 +202,15 @@ services: OLLAMA_MULTIUSER_CACHE: "false" # optimize prompt caching for multi-user scenarios OLLAMA_NOPRUNE: "false" # disables pruning of model blobs at startup OLLAMA_NOHISTORY: "true" # disables readline history - OLLAMA_FLASH_ATTENTION: "false" # enables the experimental flash attention feature - OLLAMA_KV_CACHE_TYPE: "f16" # cache quantization (f16, q8_0, or q4_0) + OLLAMA_FLASH_ATTENTION: "true" # required for OLLAMA_KV_CACHE_TYPE quantization + OLLAMA_KV_CACHE_TYPE: "f16" # cache precision: f16 (default), q8_0, q4_0 OLLAMA_SCHED_SPREAD: "false" # allows scheduling models across all GPUs. - OLLAMA_NEW_ENGINE: "true" # enables the new Ollama engine # OLLAMA_DEBUG: "true" # shows additional debug information # OLLAMA_INTEL_GPU: "true" # enables experimental Intel GPU detection + ## Telemetry / privacy opt-outs (containers do not inherit /etc/environment): + DO_NOT_TRACK: "true" + HF_HUB_DISABLE_TELEMETRY: "1" + # OLLAMA_NO_CLOUD: "1" # uncomment to disable Ollama Cloud models/features ## NVIDIA GPU Hardware Acceleration (see https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html): NVIDIA_VISIBLE_DEVICES: "all" NVIDIA_DRIVER_CAPABILITIES: "compute,utility" diff --git a/compose.yaml b/compose.yaml index 713350975..c6379d2a9 100644 --- a/compose.yaml +++ b/compose.yaml @@ -308,12 +308,15 @@ services: OLLAMA_MULTIUSER_CACHE: "false" # optimize prompt caching for multi-user scenarios OLLAMA_NOPRUNE: "false" # disables pruning of model blobs at startup OLLAMA_NOHISTORY: "true" # disables readline history - OLLAMA_FLASH_ATTENTION: "false" # enables the experimental flash attention feature - OLLAMA_KV_CACHE_TYPE: "f16" # cache quantization (f16, q8_0, or q4_0) + OLLAMA_FLASH_ATTENTION: "true" # required for OLLAMA_KV_CACHE_TYPE quantization + OLLAMA_KV_CACHE_TYPE: "f16" # cache precision: f16 (default), q8_0, q4_0 OLLAMA_SCHED_SPREAD: "false" # allows scheduling models across all GPUs. - OLLAMA_NEW_ENGINE: "true" # enables the new Ollama engine # OLLAMA_DEBUG: "true" # shows additional debug information # OLLAMA_INTEL_GPU: "true" # enables experimental Intel GPU detection + ## Telemetry / privacy opt-outs (containers do not inherit /etc/environment): + DO_NOT_TRACK: "true" + HF_HUB_DISABLE_TELEMETRY: "1" + # OLLAMA_NO_CLOUD: "1" # uncomment to disable Ollama Cloud models/features ## NVIDIA GPU Hardware Acceleration (optional): # NVIDIA_VISIBLE_DEVICES: "all" # NVIDIA_DRIVER_CAPABILITIES: "compute,utility" diff --git a/setup/docker/arm64/compose.yaml b/setup/docker/arm64/compose.yaml index cf6129ead..68a58896d 100644 --- a/setup/docker/arm64/compose.yaml +++ b/setup/docker/arm64/compose.yaml @@ -183,12 +183,15 @@ services: OLLAMA_MULTIUSER_CACHE: "false" # optimize prompt caching for multi-user scenarios OLLAMA_NOPRUNE: "false" # disables pruning of model blobs at startup OLLAMA_NOHISTORY: "true" # disables readline history - OLLAMA_FLASH_ATTENTION: "false" # enables the experimental flash attention feature - OLLAMA_KV_CACHE_TYPE: "f16" # cache quantization (f16, q8_0, or q4_0) + OLLAMA_FLASH_ATTENTION: "true" # required for OLLAMA_KV_CACHE_TYPE quantization + OLLAMA_KV_CACHE_TYPE: "f16" # cache precision: f16 (default), q8_0, q4_0 OLLAMA_SCHED_SPREAD: "false" # allows scheduling models across all GPUs. - OLLAMA_NEW_ENGINE: "true" # enables the new Ollama engine # OLLAMA_DEBUG: "true" # shows additional debug information # OLLAMA_INTEL_GPU: "true" # enables experimental Intel GPU detection + ## Telemetry / privacy opt-outs (containers do not inherit /etc/environment): + DO_NOT_TRACK: "true" + HF_HUB_DISABLE_TELEMETRY: "1" + # OLLAMA_NO_CLOUD: "1" # uncomment to disable Ollama Cloud models/features volumes: - "./ollama:/root/.ollama" diff --git a/setup/docker/compose.yaml b/setup/docker/compose.yaml index 31f9cd3e0..371a7e50c 100644 --- a/setup/docker/compose.yaml +++ b/setup/docker/compose.yaml @@ -188,12 +188,15 @@ services: OLLAMA_MULTIUSER_CACHE: "false" # optimize prompt caching for multi-user scenarios OLLAMA_NOPRUNE: "false" # disables pruning of model blobs at startup OLLAMA_NOHISTORY: "true" # disables readline history - OLLAMA_FLASH_ATTENTION: "false" # enables the experimental flash attention feature - OLLAMA_KV_CACHE_TYPE: "f16" # cache quantization (f16, q8_0, or q4_0) + OLLAMA_FLASH_ATTENTION: "true" # required for OLLAMA_KV_CACHE_TYPE quantization + OLLAMA_KV_CACHE_TYPE: "f16" # cache precision: f16 (default), q8_0, q4_0 OLLAMA_SCHED_SPREAD: "false" # allows scheduling models across all GPUs. - OLLAMA_NEW_ENGINE: "true" # enables the new Ollama engine # OLLAMA_DEBUG: "true" # shows additional debug information # OLLAMA_INTEL_GPU: "true" # enables experimental Intel GPU detection + ## Telemetry / privacy opt-outs (containers do not inherit /etc/environment): + DO_NOT_TRACK: "true" + HF_HUB_DISABLE_TELEMETRY: "1" + # OLLAMA_NO_CLOUD: "1" # uncomment to disable Ollama Cloud models/features ## NVIDIA GPU Hardware Acceleration (see https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html): # NVIDIA_VISIBLE_DEVICES: "all" # NVIDIA_DRIVER_CAPABILITIES: "compute,utility" diff --git a/setup/docker/nvidia/compose.yaml b/setup/docker/nvidia/compose.yaml index f8f725848..8caf68a17 100644 --- a/setup/docker/nvidia/compose.yaml +++ b/setup/docker/nvidia/compose.yaml @@ -188,12 +188,15 @@ services: OLLAMA_MULTIUSER_CACHE: "false" # optimize prompt caching for multi-user scenarios OLLAMA_NOPRUNE: "false" # disables pruning of model blobs at startup OLLAMA_NOHISTORY: "true" # disables readline history - OLLAMA_FLASH_ATTENTION: "false" # enables the experimental flash attention feature - OLLAMA_KV_CACHE_TYPE: "f16" # cache quantization (f16, q8_0, or q4_0) + OLLAMA_FLASH_ATTENTION: "true" # required for OLLAMA_KV_CACHE_TYPE quantization + OLLAMA_KV_CACHE_TYPE: "f16" # cache precision: f16 (default), q8_0, q4_0 OLLAMA_SCHED_SPREAD: "false" # allows scheduling models across all GPUs. - OLLAMA_NEW_ENGINE: "true" # enables the new Ollama engine # OLLAMA_DEBUG: "true" # shows additional debug information # OLLAMA_INTEL_GPU: "true" # enables experimental Intel GPU detection + ## Telemetry / privacy opt-outs (containers do not inherit /etc/environment): + DO_NOT_TRACK: "true" + HF_HUB_DISABLE_TELEMETRY: "1" + # OLLAMA_NO_CLOUD: "1" # uncomment to disable Ollama Cloud models/features ## NVIDIA GPU Hardware Acceleration (see https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/latest/install-guide.html): NVIDIA_VISIBLE_DEVICES: "all" NVIDIA_DRIVER_CAPABILITIES: "compute,utility"