homeserver/roles/xanmanning.k3s/tasks/ensure_control_plane_started_openrc.yml
mg 135bd53414 k3s - Basics (#423)
Co-authored-by: Michael Grote <michael.grote@posteo.de>
Reviewed-on: #423
2022-11-04 20:58:37 +01:00

15 lines
375 B
YAML

---
- name: Ensure k3s control plane server is started
ansible.builtin.service:
name: k3s
state: started
enabled: "{{ k3s_start_on_boot }}"
register: k3s_service_start_k3s
until: k3s_service_start_k3s is succeeded
retries: 3
delay: 3
failed_when:
- k3s_service_start_k3s is not succeeded
- not ansible_check_mode
become: "{{ k3s_become }}"