2019-04-26 21:10:27 +02:00
|
|
|
[Unit]
|
|
|
|
Description=Lightweight Kubernetes
|
|
|
|
Documentation=https://k3s.io
|
2019-04-30 01:28:58 +02:00
|
|
|
After=network-online.target
|
2020-03-01 15:01:31 +01:00
|
|
|
|
2019-04-26 21:10:27 +02:00
|
|
|
[Service]
|
2020-03-01 15:01:31 +01:00
|
|
|
Type=notify
|
2020-03-01 15:02:19 +01:00
|
|
|
ExecStartPre=-/sbin/modprobe br_netfilter
|
|
|
|
ExecStartPre=-/sbin/modprobe overlay
|
2020-07-21 14:12:20 +02:00
|
|
|
ExecStart=/usr/local/bin/k3s agent --server https://{{ master_ip }}:6443 --token {{ hostvars[groups['master'][0]]['token'] }} {{ extra_node_args | default("") }}
|
2019-04-26 21:10:27 +02:00
|
|
|
KillMode=process
|
|
|
|
Delegate=yes
|
2020-05-03 09:27:54 +02:00
|
|
|
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
|
|
|
# in the kernel. We recommend using cgroups to do container-local accounting.
|
|
|
|
LimitNOFILE=1048576
|
2019-04-26 21:10:27 +02:00
|
|
|
LimitNPROC=infinity
|
|
|
|
LimitCORE=infinity
|
|
|
|
TasksMax=infinity
|
2020-04-29 21:34:54 +02:00
|
|
|
TimeoutStartSec=0
|
2019-05-08 02:54:40 +02:00
|
|
|
Restart=always
|
2019-07-26 20:05:54 +02:00
|
|
|
RestartSec=5s
|
|
|
|
|
2019-04-26 21:10:27 +02:00
|
|
|
[Install]
|
|
|
|
WantedBy=multi-user.target
|