829ab48919
- Introduced a new SearXNG module with configuration for Kubernetes deployment, service, and ingress. - Updated existing Terraform app modules to include SearXNG in both dev-01 and prod-01 environments. - Added necessary variables and secrets for SearXNG in the respective Terraform files. - Updated Dockerfiles for llama.cpp and ollama to use latest versions. - Enhanced security and hardening defaults in Kubernetes deployments. - Improved documentation for Copilot instructions and Terraform workflows.
33 lines
1018 B
YAML
33 lines
1018 B
YAML
- name: Setup ollama
|
|
hosts: ollama
|
|
vars:
|
|
podman_user: "{{ ollama_user | default('ollama') }}"
|
|
podman_group: "{{ ollama_group | default('ollama') }}"
|
|
podman_extra_groups: "users,video"
|
|
podman_user_home: "{{ ollama_home | default('/home/ollama') }}"
|
|
podman_user_folders:
|
|
- data
|
|
pods:
|
|
- name: ollama-rocm
|
|
build:
|
|
dockerfile: "{{ lookup('file', 'dockerfiles/Dockerfile.ollama.rocm') }}"
|
|
env:
|
|
OLLAMA_CONTEXT_LENGTH: 4096
|
|
OLLAMA_NUM_THREADS: 10
|
|
OLLAMA_NUM_PARALLEL: 2
|
|
OLLAMA_FLASH_ATTENTION: 1
|
|
OLLAMA_KV_CACHE: "true"
|
|
HSA_OVERRIDE_GFX_VERSION: "11.0.0"
|
|
ports:
|
|
- "0.0.0.0:{{ ollama_port | default(11434) }}:11434/tcp"
|
|
volumes:
|
|
- "{{ ollama_home }}/data:/home/worker/.ollama:Z"
|
|
device:
|
|
- "/dev/kfd:/dev/kfd:rw"
|
|
- "/dev/dri:/dev/dri:rw"
|
|
|
|
tasks:
|
|
- name: Setup Pods
|
|
ansible.builtin.include_tasks:
|
|
file: tasks/podman.yml
|