Files
HetznerTerra/ansible/roles/k3s-registry-mirror/tasks/main.yml
T
micqdf 1896108cbb
Deploy Cluster / Terraform (push) Successful in 4m7s
Deploy Cluster / Ansible (push) Failing after 16m31s
fix: add local registry cache for rebuilds
2026-05-03 00:02:33 +00:00

21 lines
521 B
YAML

---
- name: Ensure k3s config directory exists
file:
path: /etc/rancher/k3s
state: directory
mode: "0755"
when: k3s_registry_mirror_enabled | bool
- name: Configure k3s registry mirrors
template:
src: registries.yaml.j2
dest: /etc/rancher/k3s/registries.yaml
mode: "0644"
when: k3s_registry_mirror_enabled | bool
- name: Remove k3s registry mirror config when disabled
file:
path: /etc/rancher/k3s/registries.yaml
state: absent
when: not (k3s_registry_mirror_enabled | bool)