From 06c1c4f342be841f81ab70c78a8670fadee4efd3 Mon Sep 17 00:00:00 2001 From: nsalfos <107048281+nsalfos@users.noreply.github.com> Date: Thu, 26 Jan 2023 16:56:53 +0000 Subject: [PATCH] modified script to use contianerd instead of docker and install weave network CNI --- setup-containerd.sh | 127 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100755 setup-containerd.sh diff --git a/setup-containerd.sh b/setup-containerd.sh new file mode 100755 index 0000000..72c0203 --- /dev/null +++ b/setup-containerd.sh @@ -0,0 +1,127 @@ +#!/bin/bash +# script that runs +# https://kubernetes.io/docs/setup/production-environment/container-runtime + +# setting MYOS variable +MYOS=$(hostnamectl | awk '/Operating/ { print $3 }') +OSVERSION=$(hostnamectl | awk '/Operating/ { print $4 }') + +echo printing MYOS $MYOS + +##### CentOS 7 config +if [ $MYOS = "CentOS" ] +then + if [ "$EUID" -ne 0 ] + then echo "Please run as root" + exit + fi + echo setting up CentOS 7 with containerd + # Configure prerequisites + modprobe overlay + modprobe br_netfilter + + cat <