mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-07-09 07:18:09 -02:30
Replace injected Ansible fact variables in kubespray-defaults role (#13340)
This commit is contained in:
@@ -650,12 +650,12 @@ local_volume_provisioner_storage_classes: |
|
||||
|
||||
ssl_ca_dirs: |-
|
||||
[
|
||||
{% if ansible_os_family in ['Flatcar', 'Flatcar Container Linux by Kinvolk'] -%}
|
||||
{% if ansible_facts['os_family'] in ['Flatcar', 'Flatcar Container Linux by Kinvolk'] -%}
|
||||
'/usr/share/ca-certificates',
|
||||
{% elif ansible_os_family == 'RedHat' -%}
|
||||
{% elif ansible_facts['os_family'] == 'RedHat' -%}
|
||||
'/etc/pki/tls',
|
||||
'/etc/pki/ca-trust',
|
||||
{% elif ansible_os_family == 'Debian' -%}
|
||||
{% elif ansible_facts['os_family'] == 'Debian' -%}
|
||||
'/usr/share/ca-certificates',
|
||||
{% endif -%}
|
||||
]
|
||||
@@ -755,10 +755,10 @@ _host_architecture_groups:
|
||||
aarch64: arm64
|
||||
armv7l: arm
|
||||
host_architecture: >-
|
||||
{%- if ansible_architecture in _host_architecture_groups -%}
|
||||
{{ _host_architecture_groups[ansible_architecture] }}
|
||||
{%- if ansible_facts['architecture'] in _host_architecture_groups -%}
|
||||
{{ _host_architecture_groups[ansible_facts['architecture']] }}
|
||||
{%- else -%}
|
||||
{{ ansible_architecture }}
|
||||
{{ ansible_facts['architecture'] }}
|
||||
{%- endif -%}
|
||||
|
||||
_host_os_groups:
|
||||
@@ -766,10 +766,10 @@ _host_os_groups:
|
||||
Darwin: darwin
|
||||
Win32NT: windows
|
||||
host_os: >-
|
||||
{%- if ansible_system in _host_os_groups -%}
|
||||
{{ _host_os_groups[ansible_system] }}
|
||||
{%- if ansible_facts['system'] in _host_os_groups -%}
|
||||
{{ _host_os_groups[ansible_facts['system']] }}
|
||||
{%- else -%}
|
||||
{{ ansible_system }}
|
||||
{{ ansible_facts['system'] }}
|
||||
{%- endif -%}
|
||||
|
||||
# Sets the eventRecordQPS parameter in kubelet-config.yaml.
|
||||
@@ -823,7 +823,7 @@ ntp_enabled: false
|
||||
# The default is ntp for most platforms, or chrony on RHEL/CentOS 7 and later.
|
||||
# The ntp_package can be one of ['ntp', 'ntpsec', 'chrony']
|
||||
ntp_package: >-
|
||||
{% if ansible_os_family == "RedHat" -%}
|
||||
{% if ansible_facts['os_family'] == "RedHat" -%}
|
||||
chrony
|
||||
{%- else -%}
|
||||
ntp
|
||||
|
||||
Reference in New Issue
Block a user