Fix uniontech os installation failure (#9862)
Signed-off-by: bo.jiang <bo.jiang@daocloud.io>
This commit is contained in:
@ -77,5 +77,26 @@ containerd_limit_mem_lock: "infinity"
|
|||||||
# If enabled it will use config_path and disable use mirrors config
|
# If enabled it will use config_path and disable use mirrors config
|
||||||
containerd_use_config_path: false
|
containerd_use_config_path: false
|
||||||
|
|
||||||
|
# OS distributions that already support containerd
|
||||||
|
containerd_supported_distributions:
|
||||||
|
- "CentOS"
|
||||||
|
- "OracleLinux"
|
||||||
|
- "RedHat"
|
||||||
|
- "Ubuntu"
|
||||||
|
- "Debian"
|
||||||
|
- "Fedora"
|
||||||
|
- "AlmaLinux"
|
||||||
|
- "Rocky"
|
||||||
|
- "Amazon"
|
||||||
|
- "Flatcar"
|
||||||
|
- "Flatcar Container Linux by Kinvolk"
|
||||||
|
- "Suse"
|
||||||
|
- "openSUSE Leap"
|
||||||
|
- "openSUSE Tumbleweed"
|
||||||
|
- "Kylin Linux Advanced Server"
|
||||||
|
- "UnionTech"
|
||||||
|
- "UniontechOS"
|
||||||
|
- "openEuler"
|
||||||
|
|
||||||
# If enabled it will allow kubespray to attempt setup even if the distribution is not supported. For unsupported distributions this can lead to unexpected failures in some cases.
|
# If enabled it will allow kubespray to attempt setup even if the distribution is not supported. For unsupported distributions this can lead to unexpected failures in some cases.
|
||||||
allow_unsupported_distribution_setup: false
|
allow_unsupported_distribution_setup: false
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
fail:
|
fail:
|
||||||
msg: "{{ ansible_distribution }} is not supported by containerd."
|
msg: "{{ ansible_distribution }} is not supported by containerd."
|
||||||
when:
|
when:
|
||||||
- not (allow_unsupported_distribution_setup | default(false)) and (ansible_distribution not in ["CentOS", "OracleLinux", "RedHat", "Ubuntu", "Debian", "Fedora", "AlmaLinux", "Rocky", "Amazon", "Flatcar", "Flatcar Container Linux by Kinvolk", "Suse", "openSUSE Leap", "openSUSE Tumbleweed", "Kylin Linux Advanced Server", "UnionTech", "openEuler"])
|
- not (allow_unsupported_distribution_setup | default(false)) and (ansible_distribution not in containerd_supported_distributions)
|
||||||
|
|
||||||
- name: containerd | Remove any package manager controlled containerd package
|
- name: containerd | Remove any package manager controlled containerd package
|
||||||
package:
|
package:
|
||||||
|
@ -107,3 +107,32 @@ ntp_force_sync_immediately: false
|
|||||||
|
|
||||||
# Set the timezone for your server. eg: "Etc/UTC","Etc/GMT-8". If not set, the timezone will not change.
|
# Set the timezone for your server. eg: "Etc/UTC","Etc/GMT-8". If not set, the timezone will not change.
|
||||||
ntp_timezone: ""
|
ntp_timezone: ""
|
||||||
|
|
||||||
|
# Currently known os distributions
|
||||||
|
supported_os_distributions:
|
||||||
|
- 'RedHat'
|
||||||
|
- 'CentOS'
|
||||||
|
- 'Fedora'
|
||||||
|
- 'Ubuntu'
|
||||||
|
- 'Debian'
|
||||||
|
- 'Flatcar'
|
||||||
|
- 'Flatcar Container Linux by Kinvolk'
|
||||||
|
- 'Suse'
|
||||||
|
- 'openSUSE Leap'
|
||||||
|
- 'openSUSE Tumbleweed'
|
||||||
|
- 'ClearLinux'
|
||||||
|
- 'OracleLinux'
|
||||||
|
- 'AlmaLinux'
|
||||||
|
- 'Rocky'
|
||||||
|
- 'Amazon'
|
||||||
|
- 'Kylin Linux Advanced Server'
|
||||||
|
- 'UnionTech'
|
||||||
|
- 'UniontechOS'
|
||||||
|
- 'openEuler'
|
||||||
|
|
||||||
|
# Extending some distributions into the redhat os family
|
||||||
|
redhat_os_family_extensions:
|
||||||
|
- "Kylin Linux Advanced Server"
|
||||||
|
- "openEuler"
|
||||||
|
- "UnionTech"
|
||||||
|
- "UniontechOS"
|
||||||
|
@ -22,9 +22,9 @@
|
|||||||
that: ansible_service_mgr == "systemd"
|
that: ansible_service_mgr == "systemd"
|
||||||
when: not ignore_assert_errors
|
when: not ignore_assert_errors
|
||||||
|
|
||||||
- name: Stop if unknown OS
|
- name: Stop if the os does not support
|
||||||
assert:
|
assert:
|
||||||
that: ansible_distribution in ['RedHat', 'CentOS', 'Fedora', 'Ubuntu', 'Debian', 'Flatcar', 'Flatcar Container Linux by Kinvolk', 'Suse', 'openSUSE Leap', 'openSUSE Tumbleweed', 'ClearLinux', 'OracleLinux', 'AlmaLinux', 'Rocky', 'Amazon', 'Kylin Linux Advanced Server', 'UnionTech', 'openEuler']
|
that: ansible_distribution in supported_os_distributions
|
||||||
msg: "{{ ansible_distribution }} is not a known OS"
|
msg: "{{ ansible_distribution }} is not a known OS"
|
||||||
when: not ignore_assert_errors
|
when: not ignore_assert_errors
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
set_fact:
|
set_fact:
|
||||||
ansible_os_family: "RedHat"
|
ansible_os_family: "RedHat"
|
||||||
ansible_distribution_major_version: "8"
|
ansible_distribution_major_version: "8"
|
||||||
when: ansible_distribution in ["Kylin Linux Advanced Server", "openEuler"]
|
when: ansible_distribution in redhat_os_family_extensions
|
||||||
tags:
|
tags:
|
||||||
- facts
|
- facts
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user