Skip to content

Instantly share code, notes, and snippets.

@marcinantkiewicz
Created December 6, 2025 19:59
Show Gist options
  • Select an option

  • Save marcinantkiewicz/7b558eb667dfb7dea5dee3efe6774441 to your computer and use it in GitHub Desktop.

Select an option

Save marcinantkiewicz/7b558eb667dfb7dea5dee3efe6774441 to your computer and use it in GitHub Desktop.
---
- name: install llm cli and plugins
hosts: localhost
connection: local
gather_facts: no
vars:
llm_plugins:
- llm-openrouter
- llm-mlx
tasks:
- name: install llm via homebrew
community.general.homebrew:
name: llm
state: present
update_homebrew: true
- name: get list of installed llm plugins to avoid re-installing every time playbook runs
ansible.builtin.command: llm plugins
register: installed_plugins_output
changed_when: false
- name: install plugins
ansible.builtin.command: "llm install {{ item }}"
loop: "{{ llm_plugins }}"
when: item not in installed_plugins_output.stdout
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment