remove atomic support because reached end of live (#5783)

This commit is contained in:
spaced 2020-03-17 22:31:27 +01:00 committed by GitHub
parent 820d8e6ce6
commit 8ce5a9dd19
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 27 additions and 87 deletions

View file

@ -105,7 +105,6 @@ vagrant up
- **Ubuntu** 16.04, 18.04
- **CentOS/RHEL** 7
- **Fedora** 28
- **Fedora/CentOS** Atomic
- **Fedora CoreOS** (experimental: see [fcos Note](docs/fcos.md)
- **openSUSE** Leap 42.3/Tumbleweed
- **Oracle Linux** 7

View file

@ -23,9 +23,9 @@
* [Packet](/docs/packet.md)
* [vSphere](/docs/vsphere.md)
* Operating Systems
* [Atomic](docs/atomic.md)
* [Debian](docs/debian.md)
* [Coreos](docs/coreos.md)
* [Fedora CoreOS](docs/fcos.md)
* [OpenSUSE](docs/opensuse.md)
* Advanced
* [Proxy](/docs/proxy.md)

View file

@ -1,22 +0,0 @@
# Atomic host bootstrap
Atomic host testing has been done with the network plugin flannel. Change the inventory var `kube_network_plugin: flannel`.
Note: Flannel is the only plugin that has currently been tested with atomic
## Vagrant
* For bootstrapping with Vagrant, use box centos/atomic-host or fedora/atomic-host
* Update VagrantFile variable `local_release_dir` to `/var/vagrant/temp`.
* Update `vm_memory = 2048` and `vm_cpus = 2`
* Networking on vagrant hosts has to be brought up manually once they are booted.
```ShellSession
vagrant ssh
sudo /sbin/ifup enp0s8
```
* For users of vagrant-libvirt download centos/atomic-host qcow2 format from <https://wiki.centos.org/SpecialInterestGroup/Atomic/Download/>
* For users of vagrant-libvirt download fedora/atomic-host qcow2 format from <https://dl.fedoraproject.org/pub/alt/atomic/stable/>
Then you can proceed to [cluster deployment](#run-deployment)

View file

@ -24,15 +24,6 @@
# CentOS ships with python installed
- name: Check if this is an atomic host
stat:
path: /run/ostree-booted
register: ostree
- name: Store the fact if this is an atomic host
set_fact:
is_atomic: "{{ ostree.stat.exists }}"
- name: Check presence of fastestmirror.conf
stat:
path: /etc/yum/pluginconf.d/fastestmirror.conf
@ -73,5 +64,3 @@
name: "{{ ( (ansible_distribution_major_version | int) < 8) | ternary('libselinux-python','python3-libselinux') }}"
state: present
become: true
when:
- not is_atomic

View file

@ -1,21 +1,6 @@
---
# Some Fedora based distros ship without Python installed
- name: Check if this is an atomic host
raw: stat /run/ostree-booted
register: ostree
environment: {}
failed_when: false
changed_when: false
tags:
- facts
- name: Store the fact if this is an atomic host
set_fact:
is_atomic: "{{ ostree.rc == 0 }}"
tags:
- facts
- name: Check if bootstrap is needed
raw: which python
register: need_bootstrap
@ -43,7 +28,6 @@
when:
- http_proxy is defined
- need_http_proxy.rc != 0
- not is_atomic
# Fedora's policy as of Fedora 30 is to still install python2 as /usr/bin/python
# See https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3 for the current status
@ -53,7 +37,6 @@
environment: {}
when:
- need_bootstrap.rc != 0
- not is_atomic
# libselinux-python is required on SELinux enabled hosts
# See https://docs.ansible.com/ansible/latest/installation_guide/intro_installation.html#managed-node-requirements
@ -62,5 +45,3 @@
name: libselinux-python
state: present
become: true
when:
- not is_atomic

View file

@ -12,7 +12,6 @@
with_items: "{{ containerd_repo_key_info.repo_keys }}"
when:
- ansible_os_family in ['Ubuntu', 'Debian']
- not is_atomic
- name: ensure containerd repository is enabled
action: "{{ containerd_repo_info.pkg_repo }}"
@ -22,7 +21,6 @@
with_items: "{{ containerd_repo_info.repos }}"
when:
- ansible_os_family in ['Ubuntu', 'Debian']
- not is_atomic
- containerd_repo_info.repos|length > 0
# This is required to ensure any apt upgrade will not break kubernetes
@ -34,25 +32,24 @@
mode: 0644
when:
- ansible_os_family in ['Ubuntu', 'Debian']
- not is_atomic
- name: Configure containerd repository on Fedora
template:
src: "fedora_containerd.repo.j2"
dest: "{{ yum_repo_dir }}/containerd.repo"
when: ansible_distribution == "Fedora" and not is_atomic
when: ansible_distribution == "Fedora"
- name: Configure containerd repository on RedHat/CentOS
template:
src: "rh_containerd.repo.j2"
dest: "{{ yum_repo_dir }}/containerd.repo"
when: ansible_distribution in ["CentOS","RedHat"] and not is_atomic
when: ansible_distribution in ["CentOS","RedHat"]
- name: check if container-selinux is available
yum:
list: "container-selinux"
register: yum_result
when: ansible_distribution in ["CentOS","RedHat"] and not is_atomic
when: ansible_distribution in ["CentOS","RedHat"]
- name: Configure extras repository on RedHat/CentOS if container-selinux is not available in current repos
yum_repository:
@ -66,7 +63,7 @@
keepcache: "{{ containerd_rpm_keepcache | default('1') }}"
proxy: " {{ http_proxy | default('_none_') }}"
when:
- ansible_distribution in ["CentOS","RedHat"] and not is_atomic
- ansible_distribution in ["CentOS","RedHat"]
- yum_result.results | length == 0
- name: Copy yum.conf for editing
@ -74,7 +71,7 @@
src: "{{ yum_conf }}"
dest: "{{ containerd_yum_conf }}"
remote_src: yes
when: ansible_distribution in ["CentOS","RedHat"] and not is_atomic
when: ansible_distribution in ["CentOS","RedHat"]
- name: Edit copy of yum.conf to set obsoletes=0
lineinfile:
@ -82,4 +79,4 @@
state: present
regexp: '^obsoletes='
line: 'obsoletes=0'
when: ansible_distribution in ["CentOS","RedHat"] and not is_atomic
when: ansible_distribution in ["CentOS","RedHat"]

View file

@ -1,4 +1,14 @@
---
- name: check if fedora coreos
stat:
path: /run/ostree-booted
register: ostree
- name: set is_ostree
set_fact:
is_ostree: "{{ ostree.stat.exists }}"
- name: Fail containerd setup if distribution is not supported
fail:
msg: "{{ ansible_distribution }} is not supported by containerd."
@ -25,6 +35,7 @@
- facts
- include_tasks: containerd_repo.yml
when: not is_ostree
- name: Create containerd service systemd directory if it doesn't exist
file:
@ -63,7 +74,7 @@
mode: 0644
when:
- ansible_os_family in ['Ubuntu', 'Debian']
- not is_atomic
- not is_ostree
- name: ensure containerd packages are installed
action: "{{ containerd_package_info.pkg_mgr }}"
@ -80,7 +91,7 @@
with_items: "{{ containerd_package_info.pkgs }}"
notify: restart containerd
when:
- not is_atomic
- not is_ostree
- containerd_package_info.pkgs|length > 0
ignore_errors: true
@ -101,7 +112,7 @@
delay: "{{ retry_stagger | d(3) }}"
notify: restart containerd
when:
- not is_atomic
- not is_ostree
- not runc_stat.stat.exists
- include_tasks: crictl.yml

View file

@ -1,6 +1,6 @@
---
- name: check if atomic host or fedora coreos
- name: check if fedora coreos
stat:
path: /run/ostree-booted
register: ostree

View file

@ -1,5 +1,5 @@
---
- name: check if atomic host or fedora coreos
- name: check if fedora coreos
stat:
path: /run/ostree-booted
register: ostree

View file

@ -2,7 +2,7 @@
dependencies:
- role: adduser
user: "{{ addusers.etcd }}"
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic or is_fedora_coreos)
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_fedora_coreos)
- role: adduser
user: "{{ addusers.kube }}"
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic or is_fedora_coreos)
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_fedora_coreos)

View file

@ -3,7 +3,6 @@ dependencies:
- role: adduser
user: "{{ addusers.kube }}"
when:
- not is_atomic
- not is_fedora_coreos
tags:
- kubelet

View file

@ -22,7 +22,7 @@
tags:
- facts
- name: check if atomic host
- name: check if booted with ostree
stat:
path: /run/ostree-booted
register: ostree
@ -39,15 +39,6 @@
set_fact:
is_fedora_coreos: "{{ ostree.stat.exists and os_variant_coreos is not changed }}"
- name: set is_atomic
set_fact:
is_atomic: "{{ ostree.stat.exists and not is_fedora_coreos }}"
- name: set kube_cert_group on atomic hosts
set_fact:
kube_cert_group: "kube"
when: is_atomic
- name: check resolvconf
shell: which resolvconf
register: resolvconf

View file

@ -23,7 +23,6 @@
state: absent
when:
- ansible_distribution in ["CentOS","RedHat","OracleLinux"]
- not is_atomic
- not is_fedora_coreos
- name: Install python-dnf for latest RedHat versions
@ -36,7 +35,6 @@
- ansible_distribution == "Fedora"
- ansible_distribution_major_version|int > 21
- ansible_distribution_major_version|int <= 29
- not is_atomic
- not is_fedora_coreos
changed_when: False
tags:
@ -51,7 +49,6 @@
when:
- ansible_distribution == "Fedora"
- ansible_distribution_major_version|int >= 30
- not is_atomic
- not is_fedora_coreos
changed_when: False
tags:
@ -63,7 +60,6 @@
state: present
when:
- ansible_distribution in ["CentOS","RedHat"]
- not is_atomic
- not is_fedora_coreos
- epel_enabled|bool
tags:
@ -83,7 +79,7 @@
until: pkgs_task_result is succeeded
retries: 4
delay: "{{ retry_stagger | random + 3 }}"
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic or is_fedora_coreos)
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_fedora_coreos)
tags:
- bootstrap-os

View file

@ -9,7 +9,6 @@ preinstall_selinux_state: permissive
kube_api_anonymous_auth: true
# Default value, but will be set to true automatically if detected
is_atomic: false
is_fedora_coreos: false
# optional disable the swap