mirror of
https://github.com/PyratLabs/ansible-role-k3s.git
synced 2024-11-22 11:48:22 +01:00
fix(validation): distribution and version for packages
This commit is contained in:
parent
cc8ba00de2
commit
e457854046
@ -1,13 +1,13 @@
|
||||
---
|
||||
|
||||
- include_tasks: environment/remote/packages.yml
|
||||
loop: "{{ k3s_check_packages[ansible_distribution | replace(' ', '-') | lower] }}"
|
||||
loop: "{{ k3s_check_packages[k3s_os_distribution_version] }}"
|
||||
loop_control:
|
||||
loop_var: package
|
||||
when:
|
||||
- not k3s_skip_validation
|
||||
- not k3s_skip_env_checks
|
||||
- k3s_check_packages[ansible_distribution | replace(' ', '-') | lower] is defined
|
||||
- k3s_check_packages[k3s_os_distribution_version] is defined
|
||||
|
||||
- import_tasks: configuration/variables.yml
|
||||
|
||||
|
@ -91,12 +91,17 @@ k3s_server_manifests_dir: "{{ k3s_data_dir }}/server/manifests"
|
||||
# https://github.com/k3s-io/k3s/pull/1691
|
||||
k3s_server_pod_manifests_dir: "{{ k3s_data_dir }}/agent/pod-manifests"
|
||||
|
||||
# OS formatted strings
|
||||
k3s_os_distribution: "{{ ansible_distribution | replace(' ', '-') | lower }}"
|
||||
k3s_os_version: "{{ ansible_distribution_version | replace([' ', '.'], '-') | lower }}"
|
||||
k3s_os_distribution_version: "{{ k3s_os_distribution }}-{{ k3s_os_version }}"
|
||||
|
||||
# Packages that we need to check are installed
|
||||
k3s_check_packages:
|
||||
debian:
|
||||
- name: iptables
|
||||
debian-11:
|
||||
- name: iptables-legacy
|
||||
from: 1.19.2
|
||||
until: 1.22.2
|
||||
# until: 1.22.2
|
||||
documentation: https://rancher.com/docs/k3s/latest/en/advanced/#enabling-legacy-iptables-on-raspbian-buster
|
||||
# - name: dummy
|
||||
# from: 1.19.2
|
||||
|
Loading…
Reference in New Issue
Block a user