From fa9b1a2a0116fbb93a64ac3e9b481718dce8cc60 Mon Sep 17 00:00:00 2001 From: Fabio Scotto di Santolo Date: Fri, 17 Apr 2026 14:09:29 +0200 Subject: [PATCH] Stop managing Ollama through turnstile --- AGENTS.md | 1 - README.md | 4 +- .../profile_desktop_common/tasks/main.yml | 45 ------------------- dotfiles/desktop/.config/service/ollama/run | 9 ---- 4 files changed, 2 insertions(+), 57 deletions(-) delete mode 100755 dotfiles/desktop/.config/service/ollama/run diff --git a/AGENTS.md b/AGENTS.md index e1dffb9..68ce1b9 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -54,7 +54,6 @@ Ansible-driven personal infrastructure repo for Void desktops, Linux workstation - `profile_desktop_common` owns the shared desktop bootstrap. - User services are managed by `turnstile` and live under `dotfiles/desktop/.config/service/`. - `ssh-agent` runs under `turnstile` with stable socket `~/.local/state/ssh-agent/socket`. -- `ollama` is installed from the upstream Linux tarball into `/usr/local` and runs under `turnstile`. - Critical session entrypoints: - `dotfiles/desktop/.xinitrc` - `dotfiles/desktop/.local/bin/start-sway-session` diff --git a/README.md b/README.md index 434981a..8823fdf 100644 --- a/README.md +++ b/README.md @@ -85,9 +85,9 @@ Lo stato attuale del profilo desktop include, tra le altre cose: - sessione i3 su tutti i desktop Void e sessione Sway opzionale su `nymph` - `emptty` con scelta sessione a login su `nymph` e default host-specific sugli altri desktop - pacchetti Void Linux e servizi runit -- `turnstile` per i servizi utente, inclusi `emacs`, `ssh-agent` e `ollama` +- `turnstile` per i servizi utente, inclusi `emacs` e `ssh-agent` - `ssh-agent` con socket stabile condiviso tra shell, SSH ed Emacs in `~/.local/state/ssh-agent/socket` -- `ollama` installato da tarball upstream e gestito come servizio utente `turnstile` +- `ollama` eseguito via container Podman - Flatpak con remoto Flathub - GNOME Keyring e bootstrap della posta via script dedicato - `Waybar` per Sway con `style.css` condiviso diff --git a/ansible/roles/profile_desktop_common/tasks/main.yml b/ansible/roles/profile_desktop_common/tasks/main.yml index 16d05e7..584b627 100644 --- a/ansible/roles/profile_desktop_common/tasks/main.yml +++ b/ansible/roles/profile_desktop_common/tasks/main.yml @@ -382,12 +382,6 @@ desktop_tools_tmp_dir: /tmp/desktop-tools st_repo: https://codeberg.org/fscotto/st st_src_dir: "{{ user_home }}/.local/src/st" - ollama_asset: >- - {{ - 'ollama-linux-amd64.tar.zst' if ansible_facts['architecture'] == 'x86_64' - else 'ollama-linux-arm64.tar.zst' if ansible_facts['architecture'] in ['aarch64', 'arm64'] - else '' - }} gitmux_version: v0.11.5 opencode_asset_name: >- {{ @@ -407,12 +401,6 @@ ansible.builtin.set_fact: gitmux_asset: "gitmux_{{ gitmux_version }}_linux_{{ gitmux_arch }}.tar.gz" -- name: Ensure architecture is supported for Ollama binary - tags: [packages] - ansible.builtin.fail: - msg: "Unsupported architecture {{ ansible_facts['architecture'] }} for Ollama release binary" - when: ollama_asset == '' - - name: Ensure architecture is supported for OpenCode binary tags: [packages] ansible.builtin.fail: @@ -540,36 +528,3 @@ cmd: make clean chdir: "{{ st_src_dir }}" when: st_repo_state.changed or not st_binary.stat.exists - -- name: Download Ollama release archive - tags: [packages] - ansible.builtin.get_url: - url: "https://ollama.com/download/{{ ollama_asset }}" - dest: "{{ desktop_tools_tmp_dir }}/{{ ollama_asset }}" - mode: "0644" - register: ollama_archive_download - -- name: Check whether Ollama is already installed - tags: [packages] - ansible.builtin.stat: - path: /usr/local/bin/ollama - register: ollama_install_state - -- name: Remove previous Ollama install paths when required - tags: [packages] - ansible.builtin.file: - path: /usr/local/lib/ollama - state: absent - when: - - ollama_archive_download.changed or not ollama_install_state.stat.exists - -- name: Extract Ollama release archive into /usr/local - tags: [packages] - ansible.builtin.shell: >- - zstd -d -c "{{ desktop_tools_tmp_dir }}/{{ ollama_asset }}" | - tar -xf - -C /usr/local - args: - executable: /bin/sh - changed_when: true - when: - - ollama_archive_download.changed or not ollama_install_state.stat.exists diff --git a/dotfiles/desktop/.config/service/ollama/run b/dotfiles/desktop/.config/service/ollama/run deleted file mode 100755 index 51d5f01..0000000 --- a/dotfiles/desktop/.config/service/ollama/run +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/sh - -set -eu - -if [ -n "${TURNSTILE_ENV_DIR:-}" ]; then - exec chpst -e "$TURNSTILE_ENV_DIR" /usr/local/bin/ollama serve -fi - -exec /usr/local/bin/ollama serve