Browse Source
use cri-o from upstream instead of kubic/OBS (#9374)
use cri-o from upstream instead of kubic/OBS (#9374)
* [cri-o] use cri-o from upstream instead of kubic/OBS * [cri-o] add proper molecule coverage * [skopeo] download skopeo from upstream build * [cri-o] clean up legacy deployments * disable cri-o per-distribution variablespull/9364/head
Cristian Calin
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
30 changed files with 484 additions and 435 deletions
Split View
Diff Options
-
41roles/container-engine/cri-o/defaults/main.yml
-
2roles/container-engine/cri-o/meta/main.yml
-
17roles/container-engine/cri-o/molecule/default/files/10-mynet.conf
-
10roles/container-engine/cri-o/molecule/default/files/container.json
-
10roles/container-engine/cri-o/molecule/default/files/sandbox.json
-
18roles/container-engine/cri-o/molecule/default/molecule.yml
-
46roles/container-engine/cri-o/molecule/default/prepare.yml
-
14roles/container-engine/cri-o/molecule/default/tests/test_default.py
-
119roles/container-engine/cri-o/tasks/cleanup.yaml
-
179roles/container-engine/cri-o/tasks/crio_repo.yml
-
184roles/container-engine/cri-o/tasks/main.yaml
-
38roles/container-engine/cri-o/tasks/setup-amazon.yaml
-
1roles/container-engine/cri-o/vars/almalinux-8.yml
-
15roles/container-engine/cri-o/vars/amazon.yml
-
12roles/container-engine/cri-o/vars/centos-7.yml
-
12roles/container-engine/cri-o/vars/centos-8.yml
-
6roles/container-engine/cri-o/vars/clearlinux.yml
-
25roles/container-engine/cri-o/vars/debian.yml
-
5roles/container-engine/cri-o/vars/fedora-36.yml
-
9roles/container-engine/cri-o/vars/fedora.yml
-
1roles/container-engine/cri-o/vars/oraclelinux-8.yml
-
4roles/container-engine/cri-o/vars/redhat.yml
-
1roles/container-engine/cri-o/vars/rocky-8.yml
-
22roles/container-engine/cri-o/vars/ubuntu.yml
-
32roles/container-engine/skopeo/tasks/main.yml
-
65roles/download/defaults/main.yml
-
6roles/download/tasks/set_container_facts.yml
-
2roles/kubernetes/node/tasks/facts.yml
-
22roles/kubernetes/preinstall/tasks/0070-system-packages.yml
-
1roles/kubernetes/preinstall/vars/fedora.yml
@ -1,3 +1,5 @@ |
|||
--- |
|||
dependencies: |
|||
- role: container-engine/crictl |
|||
- role: container-engine/runc |
|||
- role: container-engine/skopeo |
@ -0,0 +1,17 @@ |
|||
{ |
|||
"cniVersion": "0.2.0", |
|||
"name": "mynet", |
|||
"type": "bridge", |
|||
"bridge": "cni0", |
|||
"isGateway": true, |
|||
"ipMasq": true, |
|||
"ipam": { |
|||
"type": "host-local", |
|||
"subnet": "172.19.0.0/24", |
|||
"routes": [ |
|||
{ |
|||
"dst": "0.0.0.0/0" |
|||
} |
|||
] |
|||
} |
|||
} |
@ -0,0 +1,10 @@ |
|||
{ |
|||
"metadata": { |
|||
"name": "runc1" |
|||
}, |
|||
"image": { |
|||
"image": "quay.io/kubespray/hello-world:latest" |
|||
}, |
|||
"log_path": "runc1.0.log", |
|||
"linux": {} |
|||
} |
@ -0,0 +1,10 @@ |
|||
{ |
|||
"metadata": { |
|||
"name": "runc1", |
|||
"namespace": "default", |
|||
"attempt": 1, |
|||
"uid": "hdishd83djaidwnduwk28bcsb" |
|||
}, |
|||
"linux": {}, |
|||
"log_directory": "/tmp" |
|||
} |
@ -0,0 +1,119 @@ |
|||
--- |
|||
# TODO(cristicalin): drop this file after 2.21 |
|||
- name: CRI-O kubic repo name for debian os family |
|||
set_fact: |
|||
crio_kubic_debian_repo_name: "{{ ((ansible_distribution == 'Ubuntu') | ternary('x','')) ~ ansible_distribution ~ '_' ~ ansible_distribution_version }}" |
|||
when: ansible_os_family == "Debian" |
|||
|
|||
- name: Remove legacy CRI-O kubic apt repo key |
|||
apt_key: |
|||
url: "https://{{ crio_download_base }}/{{ crio_kubic_debian_repo_name }}/Release.key" |
|||
state: absent |
|||
when: crio_kubic_debian_repo_name is defined |
|||
|
|||
- name: Remove legacy CRI-O kubic apt repo |
|||
apt_repository: |
|||
repo: "deb http://{{ crio_download_base }}/{{ crio_kubic_debian_repo_name }}/ /" |
|||
state: absent |
|||
filename: devel-kubic-libcontainers-stable |
|||
when: crio_kubic_debian_repo_name is defined |
|||
|
|||
- name: Remove legacy CRI-O kubic cri-o apt repo |
|||
apt_repository: |
|||
repo: "deb {{ crio_download_crio }}{{ crio_version }}/{{ crio_kubic_debian_repo_name }}/ /" |
|||
state: absent |
|||
filename: devel-kubic-libcontainers-stable-cri-o |
|||
when: crio_kubic_debian_repo_name is defined |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages (CentOS_$releasever) |
|||
baseurl: http://{{ crio_download_base }}/CentOS_{{ ansible_distribution_major_version }}/ |
|||
state: absent |
|||
when: |
|||
- ansible_os_family == "RedHat" |
|||
- ansible_distribution not in ["Amazon", "Fedora"] |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }} (CentOS_$releasever)" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/CentOS_{{ ansible_distribution_major_version }}/" |
|||
state: absent |
|||
when: |
|||
- ansible_os_family == "RedHat" |
|||
- ansible_distribution not in ["Amazon", "Fedora"] |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages |
|||
baseurl: http://{{ crio_download_base }}/Fedora_{{ ansible_distribution_major_version }}/ |
|||
state: absent |
|||
when: |
|||
- ansible_distribution in ["Fedora"] |
|||
- not is_ostree |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }}" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/Fedora_{{ ansible_distribution_major_version }}/" |
|||
state: absent |
|||
when: |
|||
- ansible_distribution in ["Fedora"] |
|||
- not is_ostree |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages |
|||
baseurl: http://{{ crio_download_base }}/CentOS_7/ |
|||
state: absent |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Remove legacy CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }}" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/CentOS_7/" |
|||
state: absent |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Disable modular repos for CRI-O |
|||
ini_file: |
|||
path: "/etc/yum.repos.d/{{ item.repo }}.repo" |
|||
section: "{{ item.section }}" |
|||
option: enabled |
|||
value: 0 |
|||
mode: 0644 |
|||
become: true |
|||
when: is_ostree |
|||
loop: |
|||
- repo: "fedora-updates-modular" |
|||
section: "updates-modular" |
|||
- repo: "fedora-modular" |
|||
section: "fedora-modular" |
|||
|
|||
# Disable any older module version if we enabled them before |
|||
- name: Disable CRI-O ex module |
|||
command: "rpm-ostree ex module disable cri-o:{{ item }}" |
|||
become: true |
|||
when: |
|||
- is_ostree |
|||
- ostree_version is defined and ostree_version.stdout is version('2021.9', '>=') |
|||
with_items: |
|||
- 1.22 |
|||
- 1.23 |
|||
- 1.24 |
|||
|
|||
- name: cri-o | remove installed packages |
|||
package: |
|||
name: "{{ item }}" |
|||
state: absent |
|||
when: not is_ostree |
|||
with_items: |
|||
- cri-o |
|||
- cri-o-runc |
|||
- oci-systemd-hook |
@ -1,179 +0,0 @@ |
|||
--- |
|||
- block: |
|||
- name: Add Debian Backports apt repo |
|||
apt_repository: |
|||
repo: "deb http://deb.debian.org/debian {{ ansible_distribution_release }}-backports main" |
|||
state: present |
|||
filename: debian-backports |
|||
|
|||
- name: Set libseccomp2 pin priority to apt_preferences on Debian buster |
|||
copy: |
|||
content: | |
|||
Package: libseccomp2 |
|||
Pin: release a={{ ansible_distribution_release }}-backports |
|||
Pin-Priority: 1001 |
|||
dest: "/etc/apt/preferences.d/libseccomp2" |
|||
owner: "root" |
|||
mode: 0644 |
|||
when: |
|||
- ansible_distribution == "Debian" |
|||
- ansible_distribution_version == "10" |
|||
|
|||
- name: CRI-O kubic repo name for debian os family |
|||
set_fact: |
|||
crio_kubic_debian_repo_name: "{{ ((ansible_distribution == 'Ubuntu') | ternary('x','')) ~ ansible_distribution ~ '_' ~ ansible_distribution_version }}" |
|||
when: ansible_os_family == "Debian" |
|||
|
|||
- name: Add CRI-O kubic apt repo key |
|||
apt_key: |
|||
url: "https://{{ crio_download_base }}/{{ crio_kubic_debian_repo_name }}/Release.key" |
|||
state: present |
|||
when: crio_kubic_debian_repo_name is defined |
|||
register: apt_key_download |
|||
until: apt_key_download is succeeded |
|||
retries: 4 |
|||
delay: "{{ retry_stagger | d(3) }}" |
|||
environment: "{{ proxy_env }}" |
|||
|
|||
- name: Add CRI-O kubic apt repo |
|||
apt_repository: |
|||
repo: "deb http://{{ crio_download_base }}/{{ crio_kubic_debian_repo_name }}/ /" |
|||
state: present |
|||
filename: devel-kubic-libcontainers-stable |
|||
when: crio_kubic_debian_repo_name is defined |
|||
|
|||
- name: Add CRI-O kubic cri-o apt repo |
|||
apt_repository: |
|||
repo: "deb {{ crio_download_crio }}{{ crio_version }}/{{ crio_kubic_debian_repo_name }}/ /" |
|||
state: present |
|||
filename: devel-kubic-libcontainers-stable-cri-o |
|||
when: crio_kubic_debian_repo_name is defined |
|||
|
|||
- name: Check that amzn2-extras.repo exists |
|||
stat: |
|||
path: /etc/yum.repos.d/amzn2-extras.repo |
|||
register: amzn2_extras_file_stat |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Find docker repo in amzn2-extras.repo file |
|||
lineinfile: |
|||
dest: /etc/yum.repos.d/amzn2-extras.repo |
|||
line: "[amzn2extra-docker]" |
|||
check_mode: yes |
|||
register: amzn2_extras_docker_repo |
|||
when: |
|||
- ansible_distribution in ["Amazon"] |
|||
- amzn2_extras_file_stat.stat.exists |
|||
|
|||
- name: Remove docker repository |
|||
ini_file: |
|||
dest: /etc/yum.repos.d/amzn2-extras.repo |
|||
section: amzn2extra-docker |
|||
option: enabled |
|||
value: "0" |
|||
backup: yes |
|||
mode: 0644 |
|||
when: |
|||
- ansible_distribution in ["Amazon"] |
|||
- amzn2_extras_file_stat.stat.exists |
|||
- not amzn2_extras_docker_repo.changed |
|||
|
|||
- name: Add container-selinux yum repo |
|||
yum_repository: |
|||
name: copr:copr.fedorainfracloud.org:lsm5:container-selinux |
|||
file: _copr_lsm5-container-selinux.repo |
|||
description: Copr repo for container-selinux owned by lsm5 |
|||
baseurl: https://download.copr.fedorainfracloud.org/results/lsm5/container-selinux/epel-7-$basearch/ |
|||
gpgcheck: yes |
|||
gpgkey: https://download.copr.fedorainfracloud.org/results/lsm5/container-selinux/pubkey.gpg |
|||
skip_if_unavailable: yes |
|||
enabled: yes |
|||
repo_gpgcheck: no |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages (CentOS_$releasever) |
|||
baseurl: http://{{ crio_download_base }}/CentOS_{{ ansible_distribution_major_version }}/ |
|||
gpgcheck: yes |
|||
gpgkey: http://{{ crio_download_base }}/CentOS_{{ ansible_distribution_major_version }}/repodata/repomd.xml.key |
|||
keepcache: "0" |
|||
when: |
|||
- ansible_os_family == "RedHat" |
|||
- ansible_distribution not in ["Amazon", "Fedora"] |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }} (CentOS_$releasever)" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/CentOS_{{ ansible_distribution_major_version }}/" |
|||
gpgcheck: yes |
|||
gpgkey: "{{ crio_download_crio }}{{ crio_version }}/CentOS_{{ ansible_distribution_major_version }}/repodata/repomd.xml.key" |
|||
when: |
|||
- ansible_os_family == "RedHat" |
|||
- ansible_distribution not in ["Amazon", "Fedora"] |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages |
|||
baseurl: http://{{ crio_download_base }}/Fedora_{{ ansible_distribution_major_version }}/ |
|||
gpgcheck: yes |
|||
gpgkey: http://{{ crio_download_base }}/Fedora_{{ ansible_distribution_major_version }}/repodata/repomd.xml.key |
|||
keepcache: "0" |
|||
when: |
|||
- ansible_distribution in ["Fedora"] |
|||
- not is_ostree |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }}" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/Fedora_{{ ansible_distribution_major_version }}/" |
|||
gpgcheck: yes |
|||
gpgkey: "{{ crio_download_crio }}{{ crio_version }}/Fedora_{{ ansible_distribution_major_version }}/repodata/repomd.xml.key" |
|||
when: |
|||
- ansible_distribution in ["Fedora"] |
|||
- not is_ostree |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: devel_kubic_libcontainers_stable |
|||
description: Stable Releases of Upstream github.com/containers packages |
|||
baseurl: http://{{ crio_download_base }}/CentOS_7/ |
|||
gpgcheck: yes |
|||
gpgkey: http://{{ crio_download_base }}/CentOS_7/repodata/repomd.xml.key |
|||
keepcache: "0" |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Add CRI-O kubic yum repo |
|||
yum_repository: |
|||
name: "devel_kubic_libcontainers_stable_cri-o_{{ crio_version }}" |
|||
description: "CRI-O {{ crio_version }}" |
|||
baseurl: "{{ crio_download_crio }}{{ crio_version }}/CentOS_7/" |
|||
gpgcheck: yes |
|||
gpgkey: "{{ crio_download_crio }}{{ crio_version }}/CentOS_7/repodata/repomd.xml.key" |
|||
when: ansible_distribution in ["Amazon"] |
|||
|
|||
- name: Enable modular repos for CRI-O |
|||
ini_file: |
|||
path: "/etc/yum.repos.d/{{ item.repo }}.repo" |
|||
section: "{{ item.section }}" |
|||
option: enabled |
|||
value: 1 |
|||
mode: 0644 |
|||
become: true |
|||
when: is_ostree |
|||
loop: |
|||
- repo: "fedora-updates-modular" |
|||
section: "updates-modular" |
|||
- repo: "fedora-modular" |
|||
section: "fedora-modular" |
|||
|
|||
- name: Enable CRI-O ex module |
|||
command: "rpm-ostree ex module enable cri-o:{{ crio_version }}" |
|||
become: true |
|||
when: |
|||
- is_ostree |
|||
- ostree_version is defined and ostree_version.stdout is version('2021.9', '>=') |
@ -0,0 +1,38 @@ |
|||
--- |
|||
- name: Check that amzn2-extras.repo exists |
|||
stat: |
|||
path: /etc/yum.repos.d/amzn2-extras.repo |
|||
register: amzn2_extras_file_stat |
|||
|
|||
- name: Find docker repo in amzn2-extras.repo file |
|||
lineinfile: |
|||
dest: /etc/yum.repos.d/amzn2-extras.repo |
|||
line: "[amzn2extra-docker]" |
|||
check_mode: yes |
|||
register: amzn2_extras_docker_repo |
|||
when: |
|||
- amzn2_extras_file_stat.stat.exists |
|||
|
|||
- name: Remove docker repository |
|||
ini_file: |
|||
dest: /etc/yum.repos.d/amzn2-extras.repo |
|||
section: amzn2extra-docker |
|||
option: enabled |
|||
value: "0" |
|||
backup: yes |
|||
mode: 0644 |
|||
when: |
|||
- amzn2_extras_file_stat.stat.exists |
|||
- not amzn2_extras_docker_repo.changed |
|||
|
|||
- name: Add container-selinux yum repo |
|||
yum_repository: |
|||
name: copr:copr.fedorainfracloud.org:lsm5:container-selinux |
|||
file: _copr_lsm5-container-selinux.repo |
|||
description: Copr repo for container-selinux owned by lsm5 |
|||
baseurl: https://download.copr.fedorainfracloud.org/results/lsm5/container-selinux/epel-7-$basearch/ |
|||
gpgcheck: yes |
|||
gpgkey: https://download.copr.fedorainfracloud.org/results/lsm5/container-selinux/pubkey.gpg |
|||
skip_if_unavailable: yes |
|||
enabled: yes |
|||
repo_gpgcheck: no |
@ -1 +0,0 @@ |
|||
centos-8.yml |
@ -1,15 +0,0 @@ |
|||
--- |
|||
|
|||
crio_storage_driver: "overlay" |
|||
|
|||
crio_versioned_pkg: |
|||
"1.24": |
|||
- "cri-o-1.24.*" |
|||
"1.23": |
|||
- "cri-o-1.23.*" |
|||
"1.22": |
|||
- "cri-o-1.22.*" |
|||
|
|||
default_crio_packages: "{{ crio_versioned_pkg[crio_version] }}" |
|||
|
|||
crio_packages: "{{ centos_crio_packages | default(default_crio_packages) }}" |
@ -1,12 +0,0 @@ |
|||
--- |
|||
crio_versioned_pkg: |
|||
"1.24": |
|||
- "cri-o-1.24.*" |
|||
"1.23": |
|||
- "cri-o-1.23.*" |
|||
"1.22": |
|||
- "cri-o-1.22.*" |
|||
|
|||
default_crio_packages: "{{ crio_versioned_pkg[crio_version] }}" |
|||
|
|||
crio_packages: "{{ centos_crio_packages | default(default_crio_packages) }}" |
@ -1,12 +0,0 @@ |
|||
--- |
|||
crio_versioned_pkg: |
|||
"1.24": |
|||
- "cri-o-1.24.*" |
|||
"1.23": |
|||
- "cri-o-1.23.*" |
|||
"1.22": |
|||
- "cri-o-1.22.*" |
|||
|
|||
default_crio_packages: "{{ crio_versioned_pkg[crio_version] }}" |
|||
|
|||
crio_packages: "{{ centos_crio_packages | default(default_crio_packages) }}" |
@ -1,6 +0,0 @@ |
|||
--- |
|||
crio_packages: |
|||
- containers-basic |
|||
|
|||
crio_conmon: /usr/libexec/crio/conmon |
|||
crio_seccomp_profile: /usr/share/defaults/crio/seccomp.json |
@ -1,25 +0,0 @@ |
|||
--- |
|||
crio_versioned_pkg: |
|||
"1.24": |
|||
- "cri-o=1.24*" |
|||
- cri-o-runc |
|||
"1.23": |
|||
- "cri-o=1.23*" |
|||
- cri-o-runc |
|||
"1.22": |
|||
- "cri-o=1.22*" |
|||
- cri-o-runc |
|||
|
|||
crio_debian_buster_backports_packages: |
|||
- "libseccomp2" |
|||
|
|||
default_crio_packages: "{{ crio_versioned_pkg[crio_version] }}" |
|||
|
|||
crio_packages: "{{ debian_crio_packages | default(default_crio_packages) }}" |
|||
|
|||
# The crio_runtimes variable defines a list of OCI compatible runtimes. |
|||
crio_runtimes: |
|||
- name: runc |
|||
path: /usr/sbin/runc |
|||
type: oci |
|||
root: /run/runc |
@ -1,5 +0,0 @@ |
|||
--- |
|||
crio_packages: |
|||
- cri-o |
|||
|
|||
crio_version: 1.24 |
@ -1,9 +0,0 @@ |
|||
--- |
|||
crio_packages: |
|||
- cri-o |
|||
|
|||
crio_kubernetes_version_matrix: |
|||
"1.24": "1.23" |
|||
"1.23": "1.23" |
|||
"1.22": "1.22" |
|||
crio_version: "{{ crio_kubernetes_version_matrix[crio_required_version] | default('1.23') }}" |
@ -1 +0,0 @@ |
|||
centos-8.yml |
@ -1,4 +0,0 @@ |
|||
--- |
|||
crio_packages: |
|||
- cri-o |
|||
- oci-systemd-hook |
@ -1 +0,0 @@ |
|||
centos-8.yml |
@ -1,22 +0,0 @@ |
|||
--- |
|||
crio_versioned_pkg: |
|||
"1.24": |
|||
- "cri-o=1.24*" |
|||
- cri-o-runc |
|||
"1.23": |
|||
- "cri-o=1.23*" |
|||
- cri-o-runc |
|||
"1.22": |
|||
- "cri-o=1.22*" |
|||
- cri-o-runc |
|||
|
|||
default_crio_packages: "{{ crio_versioned_pkg[crio_version] }}" |
|||
|
|||
crio_packages: "{{ ubuntu_crio_packages | default(default_crio_packages) }}" |
|||
|
|||
# The crio_runtimes variable defines a list of OCI compatible runtimes. |
|||
crio_runtimes: |
|||
- name: runc |
|||
path: /usr/sbin/runc |
|||
type: oci |
|||
root: /run/runc |
@ -0,0 +1,32 @@ |
|||
--- |
|||
- name: skopeo | check if fedora coreos |
|||
stat: |
|||
path: /run/ostree-booted |
|||
get_attributes: no |
|||
get_checksum: no |
|||
get_mime: no |
|||
register: ostree |
|||
|
|||
- name: skopeo | set is_ostree |
|||
set_fact: |
|||
is_ostree: "{{ ostree.stat.exists }}" |
|||
|
|||
- name: skopeo | Uninstall skopeo package managed by package manager |
|||
package: |
|||
name: skopeo |
|||
state: absent |
|||
when: |
|||
- not (is_ostree or (ansible_distribution == "Flatcar Container Linux by Kinvolk") or (ansible_distribution == "Flatcar")) |
|||
ignore_errors: true # noqa ignore-errors |
|||
|
|||
- name: skopeo | Download skopeo binary |
|||
include_tasks: "../../../download/tasks/download_file.yml" |
|||
vars: |
|||
download: "{{ download_defaults | combine(downloads.skopeo) }}" |
|||
|
|||
- name: Copy skopeo binary from download dir |
|||
copy: |
|||
src: "{{ downloads.skopeo.dest }}" |
|||
dest: "{{ bin_dir }}/skopeo" |
|||
mode: 0755 |
|||
remote_src: true |
Write
Preview
Loading…
Cancel
Save