mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-03-06 18:17:47 +03:00
Add cri-o role.
This commit is contained in:
40
roles/cri-o/tasks/main.yaml
Normal file
40
roles/cri-o/tasks/main.yaml
Normal file
@@ -0,0 +1,40 @@
|
||||
---
|
||||
- name: Add OpenShift Origin repository
|
||||
yum_repository:
|
||||
name: origin
|
||||
description: OpenShift Origin Repo
|
||||
baseurl: "{{ crio_rhel_repo_base_url }}"
|
||||
gpgcheck: no
|
||||
when:
|
||||
- ansible_os_family == 'RedHat'
|
||||
|
||||
- name: Install cri-o
|
||||
package:
|
||||
name: "{{ item }}"
|
||||
state: present
|
||||
with_items:
|
||||
- cri-o
|
||||
- cri-tools
|
||||
- oci-systemd-hook
|
||||
|
||||
- name: Install cri-o config
|
||||
template:
|
||||
src: crio.conf.j2
|
||||
dest: /etc/crio/crio.conf
|
||||
|
||||
- name: Copy mounts.conf
|
||||
shell: |
|
||||
cp -T /usr/share/containers/mounts.conf /etc/containers/mounts.conf
|
||||
|
||||
- name: Create directory for oci hooks
|
||||
file:
|
||||
path: /etc/containers/oci/hooks.d
|
||||
state: directory
|
||||
owner: root
|
||||
mode: 0755
|
||||
|
||||
- name: Install cri-o service
|
||||
service:
|
||||
name: crio
|
||||
enabled: yes
|
||||
state: restarted
|
||||
Reference in New Issue
Block a user