diff --git a/ollama-0.5.7.obscpio b/ollama-0.5.7.obscpio index 966647f..6696d60 100644 --- a/ollama-0.5.7.obscpio +++ b/ollama-0.5.7.obscpio @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9f6e6167b56b0baa6cf06ec12d6897c711e8d8f15bf060ba7bb56767a3cd12c5 -size 17290765 +oid sha256:efb1f1510c40a71f933e8b1ad3b88acb499f017e1bfd271492d9ccf5b7a69d2c +size 154515982 diff --git a/ollama.changes b/ollama.changes index da0d0c1..72db136 100644 --- a/ollama.changes +++ b/ollama.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Mon Jan 27 14:21:42 UTC 2025 - Adrian Schröter + +- Make ollama configurable by the admin via /etc/sysconfig/ollama + (boo#1236008) +- cleanup reproducible.patch + ------------------------------------------------------------------- Thu Jan 16 23:52:45 UTC 2025 - Eyad Issa diff --git a/ollama.service b/ollama.service index 22828b1..42eb593 100644 --- a/ollama.service +++ b/ollama.service @@ -8,6 +8,7 @@ User=ollama Group=ollama Restart=always RestartSec=3 +EnvironmentFile=-/etc/sysconfig/ollama [Install] WantedBy=default.target diff --git a/ollama.spec b/ollama.spec index 1f05e55..a6f2108 100644 --- a/ollama.spec +++ b/ollama.spec @@ -26,7 +26,7 @@ Source: %{name}-%{version}.tar Source1: vendor.tar.zstd Source2: ollama.service Source3: %{name}-user.conf -#Patch1: reproducible.patch +Source4: sysconfig.ollama BuildRequires: cmake >= 3.24 BuildRequires: git BuildRequires: sysuser-tools @@ -41,6 +41,7 @@ BuildRequires: libstdc++6-gcc12 %else BuildRequires: gcc-c++ >= 11.4.0 %endif +Requires(pre): %{fillup_prereq} %description Ollama is a tool for running AI models on one's own hardware. @@ -75,6 +76,7 @@ install -D -m 0755 %{name} %{buildroot}/%{_bindir}/%{name} install -D -m 0644 %{SOURCE2} %{buildroot}%{_unitdir}/%{name}.service install -D -m 0644 %{SOURCE3} %{buildroot}%{_sysusersdir}/%{name}-user.conf +install -D -m 0644 %{SOURCE4} %{buildroot}%{_fillupdir}/sysconfig.%name install -d %{buildroot}%{_localstatedir}/lib/%{name} mkdir -p "%{buildroot}/%{_docdir}/%{name}" @@ -94,6 +96,7 @@ go test -v ./... %post %service_add_post %{name}.service +%fillup_only %preun %service_del_preun %{name}.service @@ -108,6 +111,7 @@ go test -v ./... %{_bindir}/%{name} %{_unitdir}/%{name}.service %{_sysusersdir}/%{name}-user.conf +%{_fillupdir}/sysconfig.%name %attr(-, ollama, ollama) %{_localstatedir}/lib/%{name} %changelog diff --git a/reproducible.patch b/reproducible.patch deleted file mode 100644 index 6066adc..0000000 --- a/reproducible.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/llama/make/Makefile.default b/llama/make/Makefile.default -index 6a9b9ef..2ab7dfe 100644 ---- a/llama/make/Makefile.default -+++ b/llama/make/Makefile.default -@@ -42,7 +42,7 @@ $(RUNNERS_DIST_DIR)/%: $(RUNNERS_BUILD_DIR)/% - - $(RUNNERS_PAYLOAD_DIR)/%/ollama_llama_server$(EXE_EXT).gz: $(RUNNERS_BUILD_DIR)/%/ollama_llama_server$(EXE_EXT) - @-mkdir -p $(dir $@) -- ${GZIP} --best -c $< > $@ -+ ${GZIP} -n --best -c $< > $@ - - clean: - rm -f $(BUILD_RUNNERS) $(DIST_RUNNERS) $(PAYLOAD_RUNNERS) diff --git a/sysconfig.ollama b/sysconfig.ollama new file mode 100644 index 0000000..06184e0 --- /dev/null +++ b/sysconfig.ollama @@ -0,0 +1,58 @@ +## Path: Network/Ollama +## Description: Ollama server access +## Type: string +## Default: "http://127.0.0.1:11434" +## ServiceRestart: ollama +# +# set it to 0.0.0.0 for global network access +# +OLLAMA_HOST="http://127.0.0.1:11434" + +## Type: string +## Description: Ollama default quantization type for the K/V cache +## Default: "f16" +## ServiceRestart: ollama +OLLAMA_KV_CACHE_TYPE=f16 + +## Type: string +## Description: Ollama default quantization type for the K/V cache +## Default: "f16" +## ServiceRestart: ollama +OLLAMA_KEEP_ALIVE= + +## Type: string +## Description: Parallel processes +## Default: "" +## ServiceRestart: ollama +OLLAMA_NUM_PARALLEL= + +## Type: string +## Description: Maxmimal memory to be used +## Default: "" +## ServiceRestart: ollama +OLLAMA_MAX_VRAM= + +## Type: string +## Description: Ollama runner directory +## Default: "" +## ServiceRestart: ollama +OLLAMA_RUNNERS_DIR= + +## Type: string +## Description: Ollama temporary directory +## Default: "" +## ServiceRestart: ollama +OLLAMA_TMPDIR= + +## Type: string +## Description: Models to be loaded by default +## Default: "" +## ServiceRestart: ollama +OLLAMA_MODELS= + +## Type: string +## Description: List of allowed remote hosts +## Default: "" +## ServiceRestart: ollama +OLLAMA_ORIGINS= + diff --git a/vendor.tar.zstd b/vendor.tar.zstd index 2d201a0..186a849 100644 --- a/vendor.tar.zstd +++ b/vendor.tar.zstd @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e032bb67f22c27d950b3b9412a5b08153f40c96bf88525b0ade106c48b4b0b1b -size 5374821 +oid sha256:8859600b0cadcc09f5301ff86e18d25676e263146758e949aa614a5d6819e829 +size 5374849