mirror of
https://github.com/k3s-io/k3s-ansible.git
synced 2026-03-10 12:12:12 +01:00
Fix getting random token for agents
Signed-off-by: Derek Nola <derek.nola@suse.com>
This commit is contained in:
@@ -65,9 +65,10 @@
|
||||
register: _agent_config_result
|
||||
|
||||
- name: Get the token from the first server
|
||||
when: token is not defined and hostvars[groups[server_group][0]].random_token is defined
|
||||
# noqa var-naming[no-role-prefix]
|
||||
ansible.builtin.set_fact:
|
||||
token: "{{ hostvars[groups[server_group][0]].token }}"
|
||||
token: "{{ hostvars[groups[server_group][0]].random_token }}"
|
||||
|
||||
- name: Set k3s agent environment file based on init system
|
||||
ansible.builtin.set_fact:
|
||||
|
||||
Reference in New Issue
Block a user