Fix adding token to existing cluster (#360)

Signed-off-by: James Otten <jamesotten1@gmail.com>
This commit is contained in:
james-otten 2024-09-12 12:54:11 -04:00 committed by GitHub
parent 2d98982809
commit bc03d1c0d0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -35,13 +35,13 @@
INSTALL_K3S_EXEC: "agent"
changed_when: true
- name: Add the token for joining the cluster to the environment
no_log: true # avoid logging the server token
ansible.builtin.lineinfile:
path: "{{ systemd_dir }}/k3s-agent.service.env"
line: "{{ item }}"
with_items:
- "K3S_TOKEN={{ token }}"
- name: Add the token for joining the cluster to the environment
no_log: true # avoid logging the server token
ansible.builtin.lineinfile:
path: "{{ systemd_dir }}/k3s-agent.service.env"
line: "{{ item }}"
with_items:
- "K3S_TOKEN={{ token }}"
- name: Copy K3s service file
register: k3s_agent_service