Skip to content
Snippets Groups Projects
Unverified Commit c9429155 authored by Marcus Fenner's avatar Marcus Fenner Committed by GitHub
Browse files

Fix containerd install for fcos (#8107)

* Fix containerd install for fcos

* rm orphaned runc and containerd binaries
parent 8d553f7e
No related branches found
No related tags found
No related merge requests found
......@@ -57,6 +57,19 @@
- --strip-components=1
notify: restart containerd
- name: containerd | Remove orphaned binary
file:
path: "/usr/bin/{{ item }}"
state: absent
when: containerd_bin_dir != "/usr/bin"
ignore_errors: true # noqa ignore-errors
with_items:
- containerd
- containerd-shim
- containerd-shim-runc-v1
- containerd-shim-runc-v2
- ctr
- name: containerd | Generate systemd service for containerd
template:
src: containerd.service.j2
......
---
runc_bin_dir: /usr/bin/
runc_bin_dir: "{{ bin_dir }}"
runc_package_name: runc
---
- name: runc | set is_ostree
set_fact:
is_ostree: "{{ ostree.stat.exists }}"
- name: runc | Uninstall runc package managed by package manager
package:
name: "{{ runc_package_name }}"
state: absent
when:
- not (is_ostree or (ansible_distribution == "Flatcar Container Linux by Kinvolk") or (ansible_distribution == "Flatcar"))
- name: runc | Download runc binary
include_tasks: "../../../download/tasks/download_file.yml"
......@@ -15,3 +21,10 @@
dest: "{{ runc_bin_dir }}/runc"
mode: 0755
remote_src: true
- name: runc | Remove orphaned binary
file:
path: /usr/bin/runc
state: absent
when: runc_bin_dir != "/usr/bin"
ignore_errors: true # noqa ignore-errors
......@@ -67,7 +67,7 @@ haproxy_config_dir: "/etc/haproxy"
# Directory where the binaries will be installed
bin_dir: /usr/local/bin
docker_bin_dir: /usr/bin
containerd_bin_dir: /usr/bin
containerd_bin_dir: "{{ bin_dir }}"
etcd_data_dir: /var/lib/etcd
# Where the binaries will be downloaded.
# Note: ensure that you've enough disk space (about 1G)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment