mirror of
https://github.com/k3s-io/k3s-ansible.git
synced 2025-12-25 00:12:37 +01:00
Enforce use of a defined token. Simplifies additional server and agent joining process.
Signed-off-by: Derek Nola <derek.nola@suse.com>
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
---
|
||||
k3s_server_location: "/var/lib/rancher/k3s"
|
||||
systemd_dir: "/etc/systemd/system"
|
||||
api_port: 6443
|
||||
|
||||
@@ -7,7 +7,7 @@ After=network-online.target
|
||||
Type=notify
|
||||
ExecStartPre=-/sbin/modprobe br_netfilter
|
||||
ExecStartPre=-/sbin/modprobe overlay
|
||||
ExecStart=/usr/local/bin/k3s agent --data-dir {{ k3s_server_location }} --server https://{{ api_endpoint }}:{{ api_port }} --token {{ hostvars[groups['server'][0]]['token'] }} {{ extra_agent_args }}
|
||||
ExecStart=/usr/local/bin/k3s agent --data-dir {{ k3s_server_location }} --server https://{{ api_endpoint }}:{{ api_port }} --token {{ token }} {{ extra_agent_args }}
|
||||
KillMode=process
|
||||
Delegate=yes
|
||||
# Having non-zero Limit*s causes performance problems due to accounting overhead
|
||||
|
||||
Reference in New Issue
Block a user