prole/infrastructure/playbooks/k3s_install_single.yml
chrisfu 5dcd3b9581 ansible: treat /var/lib/rancher as local K3s state
Update inventory/roles to keep K3s state on local storage and prevent iSCSI from managing /var/lib/rancher.

Also add a single-host k3s install playbook, a systemd override template, and docs describing the installer ↔ Ansible boundary and slow-storage knobs.

Co-authored-by: Junie <junie@jetbrains.com>
2026-03-15 23:20:55 -07:00

25 lines
566 B
YAML

---
- name: Install and start k3s on a single host
hosts: k3s_hosts
gather_facts: false
become: true
serial: 1
pre_tasks:
- name: Require a single host target
ansible.builtin.assert:
that:
- ansible_play_hosts_all | length == 1
fail_msg: "This playbook targets one host. Use --limit <host>."
- name: Gather minimal facts
ansible.builtin.setup:
gather_subset:
- min
tasks:
- name: Install and start k3s
ansible.builtin.import_role:
name: k3s
tasks_from: install