Install Packages

Install cri-o packages (on Ubuntu 20.04 LTS):
#author:  Thomas Roehm
#version: 1.1
export VERSION=1.25
export OS="xUbuntu_20.04"                          #must match os version
echo ""
echo "checkout ''"
echo "checkout''"
echo ""
echo "adding '/debian buster-backports main' repository"
sleep 3
echo ""
echo 'deb 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$OS/ /" > /etc/apt/sources.list.d/devel:kubic:libcontainers:stable.list
echo "deb$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$VERSION/$OS/Release.key | apt-key add -
curl -L$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


crictl info
crictl images
crictl --help
crictl pull image
sudo crictl runp net-pod.json
sudo crictl create nginx.json net-pod.json
sudo crictl ps -a
echo "source <(crictl completion bash)" >> .bashrc                                                     #bash autocompletion
sudo curl -v --unix-socket /var/run/crio/crio.sock http://localhost/info | jq                          #check if running and show e. g. cgroup_driver


docker/cri-o.txt · Last modified: 2024/01/11 20:54 by tmade
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Noncommercial-Share Alike 4.0 International
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki