actualized for kubespray version 2.28.0
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
---
|
||||
- name: Cri-o | include vars/v1.28.yml
|
||||
include_vars: v1.28.yml
|
||||
when: crio_version is version("v1.29.0", operator="<")
|
||||
|
||||
- name: Cri-o | include vars/v1.29.yml
|
||||
include_vars: v1.29.yml
|
||||
when: crio_version is version("v1.29.0", operator=">=")
|
||||
when: crio_version is version("1.29.0", operator=">=")
|
||||
|
||||
- name: Cri-o | include vars/v1.31.yml
|
||||
include_vars: v1.31.yml
|
||||
when: crio_version is version("1.31.0", operator=">=")
|
||||
|
||||
@@ -36,11 +36,18 @@
|
||||
when:
|
||||
- kata_containers_enabled
|
||||
|
||||
- name: Cri-o | build a list of crio runtimes with crun runtime
|
||||
## After CRI-O v1.31, crun is default runtime.
|
||||
# - name: Cri-o | build a list of crio runtimes with crun runtime
|
||||
# set_fact:
|
||||
# crio_runtimes: "{{ crio_runtimes + [crun_runtime] }}"
|
||||
# when:
|
||||
# - crun_enabled
|
||||
|
||||
- name: Cri-o | build a list of crio runtimes with runc runtime
|
||||
set_fact:
|
||||
crio_runtimes: "{{ crio_runtimes + [crun_runtime] }}"
|
||||
crio_runtimes: "{{ crio_runtimes + [runc_runtime] }}"
|
||||
when:
|
||||
- crun_enabled
|
||||
- runc_enabled
|
||||
|
||||
- name: Cri-o | build a list of crio runtimes with youki runtime
|
||||
set_fact:
|
||||
@@ -82,6 +89,23 @@
|
||||
- "{{ crio_bin_files }}"
|
||||
notify: Restart crio
|
||||
|
||||
- name: Cri-o | create directory for libexec
|
||||
file:
|
||||
path: "{{ crio_libexec_dir }}"
|
||||
state: directory
|
||||
owner: root
|
||||
mode: "0755"
|
||||
|
||||
- name: Cri-o | copy libexec
|
||||
copy:
|
||||
src: "{{ local_release_dir }}/cri-o/bin/{{ item }}"
|
||||
dest: "{{ crio_libexec_dir }}/{{ item }}"
|
||||
mode: "0755"
|
||||
remote_src: true
|
||||
with_items:
|
||||
- "{{ crio_libexec_files }}"
|
||||
notify: Restart crio
|
||||
|
||||
- name: Cri-o | copy service file
|
||||
copy:
|
||||
src: "{{ local_release_dir }}/cri-o/contrib/crio.service"
|
||||
@@ -156,7 +180,7 @@
|
||||
dest: /etc/containers/storage.conf
|
||||
section: storage.options.overlay
|
||||
option: mountopt
|
||||
value: '{{ ''"nodev"'' if ansible_kernel is version_compare(("4.18" if ansible_os_family == "RedHat" else "4.19"), "<") else ''"nodev,metacopy=on"'' }}'
|
||||
value: '{{ ''"nodev"'' if ansible_kernel is version(("4.18" if ansible_os_family == "RedHat" else "4.19"), "<") else ''"nodev,metacopy=on"'' }}'
|
||||
mode: "0644"
|
||||
|
||||
- name: Cri-o | create directory registries configs
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
- name: CRI-O | Remove cri-o apt repo
|
||||
apt_repository:
|
||||
repo: "deb {{ crio_download_crio }}{{ crio_version }}/{{ crio_kubic_debian_repo_name }}/ /"
|
||||
repo: "deb {{ crio_download_crio }}v{{ crio_version }}/{{ crio_kubic_debian_repo_name }}/ /"
|
||||
state: absent
|
||||
filename: devel-kubic-libcontainers-stable-cri-o
|
||||
when: crio_kubic_debian_repo_name is defined
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
- name: CRI-O | Remove CRI-O kubic yum repo
|
||||
yum_repository:
|
||||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}"
|
||||
name: "devel_kubic_libcontainers_stable_cri-o_v{{ crio_version }}"
|
||||
state: absent
|
||||
when:
|
||||
- ansible_os_family == "RedHat"
|
||||
@@ -88,3 +88,11 @@
|
||||
with_items: "{{ crio_bin_files }}"
|
||||
tags:
|
||||
- reset_crio
|
||||
|
||||
- name: CRI-O | Remove CRI-O libexec
|
||||
file:
|
||||
name: "{{ item }}"
|
||||
state: absent
|
||||
with_items: "{{ crio_libexec_files }}"
|
||||
tags:
|
||||
- reset_crio
|
||||
|
||||
Reference in New Issue
Block a user