PyratLabs / ansible-role-k3s

Ansible role for installing k3s as either a standalone server or HA cluster.
BSD 3-Clause "New" or "Revised" License
627 stars 135 forks source link

add k3s_service_exec_start_pre_vars for the k3s service #226

Open longns1 opened 1 month ago

longns1 commented 1 month ago

Add k3s_service_exec_start_pre_vars for the k3s service. This dictionary can be used to specify additional ExecStartPre commands for the k3s service. These commands will be executed before the main service starts.

For example, the command below removes the cpu_manager_state file if it exists.


k3s_service_exec_start_pre_vars:
   - "-/usr/bin/rm -f /var/lib/kubelet/cpu_manager_state"