#!/bin/bash #author: Thomas Roehm #version: 1.1 export VERSION=1.25 export OS="xUbuntu_20.04" #must match os version echo "" echo "checkout 'https://github.com/cri-o/cri-o/blob/main/install.md#apt-based-operating-systems'" echo "checkout'https://cri-o.io/'" echo "" echo "adding '/debian buster-backports main' repository" sleep 3 echo "" echo 'deb http://deb.debian.org/debian buster-backports main' > /etc/apt/sources.list.d/backports.list apt update echo "" echo "installing buster-backports" sleep 3 echo "" apt install -y -t buster-backports libseccomp2 || apt update -y -t buster-backports libseccomp2 apt-mark unhold cri-o cri-o-runc cri-tools echo "" echo "adding required repositories" echo "" echo "deb https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/$OS/ /" > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list echo "deb http://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable:/cri-o:/$VERSION/$OS/ /" > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable:cri-o:$VERSION.list sleep 3 echo "Install repositories" sleep 3 echo "" mkdir -p /usr/share/keyrings curl -L https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable:/cri-o:/$VERSION/$OS/Release.key | apt-key add - curl -L https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/$OS/Release.key | apt-key add - sleep 3 echo "" apt-get update echo "" echo "install cri-o, cri-o-runc and cri-tool" sleep 3 echo "" apt-get install cri-o cri-o-runc cri-tools apt-mark hold cri-o cri-o-runc cri-tools systemctl enable crio.service systemctl start crio.service echo "" echo "crio installed" sleep 3 echo "" systemctl status crio.service