mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-03-09 11:47:47 +03:00
Cleanup of kubernetes/preinstall (#11010)
* Move fedora ansible python install to bootstrap-os
* /bin/dir is set in bootstrap-os
* Removing ansible_os_family workarounds
Support for these distributions was merged in Ansible, no need to
override it ourselves now.
https://github.com/ansible/ansible/pull/69324 openEuler
https://github.com/ansible/ansible/pull/77275/ UnionTech OS Server 20
https://github.com/ansible/ansible/pull/78232/ Kylin
* Don't unconditionnaly set VARIANT_ID=coreos in os-release
WTF, this is so wrong.
Furthermore, is_fedora_coreos is already handled in boostrap-os
* Handle Clearlinux generically
Followup of 4eec302e86 (since we're using
package module anyway, let's get rid of the custom task)
This commit is contained in:
@@ -1,11 +1,4 @@
|
||||
---
|
||||
- name: Force binaries directory for Flatcar Container Linux by Kinvolk
|
||||
set_fact:
|
||||
bin_dir: "/opt/bin"
|
||||
when: ansible_os_family in ["Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||
tags:
|
||||
- facts
|
||||
|
||||
- name: Set os_family fact for other redhat-based operating systems
|
||||
set_fact:
|
||||
ansible_os_family: "RedHat"
|
||||
@@ -14,34 +7,6 @@
|
||||
tags:
|
||||
- facts
|
||||
|
||||
- name: Set os_family fact for other debian-based operating systems
|
||||
set_fact:
|
||||
ansible_os_family: "Debian"
|
||||
when: ansible_distribution in debian_os_family_extensions
|
||||
tags:
|
||||
- facts
|
||||
|
||||
- name: Check if booted with ostree
|
||||
stat:
|
||||
path: /run/ostree-booted
|
||||
get_attributes: no
|
||||
get_checksum: no
|
||||
get_mime: no
|
||||
register: ostree
|
||||
|
||||
- name: Set is_fedora_coreos
|
||||
lineinfile:
|
||||
path: /etc/os-release
|
||||
line: "VARIANT_ID=coreos"
|
||||
state: present
|
||||
check_mode: yes
|
||||
register: os_variant_coreos
|
||||
changed_when: false
|
||||
|
||||
- name: Set is_fedora_coreos
|
||||
set_fact:
|
||||
is_fedora_coreos: "{{ ostree.stat.exists and os_variant_coreos is not changed }}"
|
||||
|
||||
- name: Check resolvconf
|
||||
command: which resolvconf
|
||||
register: resolvconf
|
||||
|
||||
Reference in New Issue
Block a user