2022-10-03 20:58:05 +00:00
|
|
|
#jinja2: lstrip_blocks: True
|
|
|
|
{{ ansible_managed | comment }}
|
|
|
|
[Unit]
|
|
|
|
Description=K3s Kubernetes
|
|
|
|
Documentation=https://k3s.io
|
|
|
|
After=network-online.target
|
|
|
|
|
|
|
|
[Service]
|
|
|
|
Type=notify
|
|
|
|
ExecStartPre=-/sbin/modprobe br_netfilter
|
|
|
|
ExecStartPre=-/sbin/modprobe overlay
|
2022-10-17 19:26:56 +00:00
|
|
|
ExecStart={{ __k3s_binary }} {{ "server" if k3s_server | bool else "agent" }} --config {{ __k3s_config_dir }}/config.yaml
|
2022-10-03 20:58:05 +00:00
|
|
|
KillMode=process
|
|
|
|
Delegate=yes
|
|
|
|
LimitNOFILE=1048576
|
|
|
|
LimitNPROC=infinity
|
|
|
|
LimitCORE=infinity
|
|
|
|
TasksMax=infinity
|
|
|
|
TimeoutStartSec=0
|
|
|
|
Restart=always
|
|
|
|
RestartSec=5s
|
|
|
|
|
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|