mirror of
https://github.com/k3s-io/k3s-ansible.git
synced 2025-12-25 00:12:37 +01:00
Inject installation envs for install script (#433)
Signed-off-by: Derek Nola <derek.nola@suse.com>
This commit is contained in:
@@ -33,11 +33,15 @@
|
||||
loop: "{{ k3s_service_files.files }}"
|
||||
|
||||
- name: Install new K3s Version
|
||||
ansible.builtin.command:
|
||||
# For some reason, ansible-lint thinks using enviroment with command is an error
|
||||
# even though its valid https://ansible.readthedocs.io/projects/lint/rules/inline-env-var/#correct-code
|
||||
ansible.builtin.command: # noqa inline-env-var
|
||||
cmd: /usr/local/bin/k3s-install.sh
|
||||
environment:
|
||||
INSTALL_K3S_SKIP_START: "true"
|
||||
INSTALL_K3S_VERSION: "{{ k3s_version }}"
|
||||
environment: >-
|
||||
{{ extra_install_envs | combine({
|
||||
"INSTALL_K3S_SKIP_START": "true",
|
||||
"INSTALL_K3S_VERSION": k3s_version,
|
||||
}) }}
|
||||
changed_when: true
|
||||
|
||||
- name: Restore K3s service
|
||||
|
||||
Reference in New Issue
Block a user