Ollama Service

References Ollama.com Installation curl -fsSL https://ollama.com/install.sh | sh Useful Commands sudo usermod -aG ollama $USER ollama pull llama3 llama2-uncensored godegemma gemma dolphin-mistral Service Configuration [Unit] Description=Ollama Service After=network-online.target [Service] ExecStart=/usr/local/bin/ollama serve User=ollama Group=ollama Restart=always RestartSec=3 Environment="PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin" Environment="OLLAMA_HOST=0.0.0.0" [Install] WantedBy=default.target Useful Plugins Obsidian: local gpt Openweb-UI Misc Information Service runs on port 11433 By default service only listens on local host

July 3, 2024 · welcome-2themachine

Openweb-UI

References: Open WebUI Open WebUI Troubleshooting Searxng Integration This is my error… Setup Main docker run -d -p 8080:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui --restart always ghcr.io/open-webui/open-webui:main Latest docker run -d -p 8080:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui --restart always ghcr.io/open-webui/open-webui:latest Docker Compose Yaml version: "3" services: open-webui: image: ghcr.io/open-webui/open-webui:latest container_name: open-webui volumes: - /home/mechanicus/open-webui:/app/backend/data restart: unless-stopped port: - "8080:8080" extra_hosts: - "host.docker.internal:host-gateway" Updates Pull the new image (make sure you pick main or latest based on your install) docker pull ghcr.io/open-webui/open-webui:latest Remove the old container docker rm --force open-webui Start the new container by rerunning the setup command docker run -d -p 8080:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui --restart always ghcr.io/open-webui/open-webui:latest (Optional) Let [[Watchtower]] Do it docker run -d --name watchtower --volume /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower open-webui Troubleshooting Resetting the admin password on a local instance - generate a new password hash htpasswd -bnBC 10 "" your-new-password | tr -d ':\n' Change the password using a new docker container - replace HASH with the new password hash you just generated. docker run --rm -v open-webui:/data alpine/socat EXEC:"bash -c 'apk add sqlite && echo UPDATE auth SET password='\''HASH'\'' WHERE email='\''admin@example.com'\''; | sqlite3 /data/webui.db'", STDIO Data needs to be directly in the base folder for a mapped volume (Docker volumes use _data within a volume folder). [[Searxng]] needs the following changes to searxng/settings.yml: search: safe_search: 0 autocomplete: "" default_lang: "" formats: - html - json

July 3, 2024 · welcome-2themachine