mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 12:15:52 +00:00
Source containerd env for repo installation
Signed-off-by: Aditi Sharma <adi.sky17@gmail.com>
This commit is contained in:
parent
1c216c6ec8
commit
a251acdfc7
@ -586,19 +586,23 @@ function ensure-container-runtime {
|
|||||||
if [[ -n "${UBUNTU_INSTALL_CONTAINERD_VERSION:-}" || -n "${UBUNTU_INSTALL_RUNC_VERSION:-}" ]]; then
|
if [[ -n "${UBUNTU_INSTALL_CONTAINERD_VERSION:-}" || -n "${UBUNTU_INSTALL_RUNC_VERSION:-}" ]]; then
|
||||||
log-wrap "InstallContainerdUbuntu" install-containerd-ubuntu
|
log-wrap "InstallContainerdUbuntu" install-containerd-ubuntu
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# when custom containerd version is installed sourcing containerd_env.sh will add all tools like ctr to the PATH
|
||||||
|
if [[ -e "/etc/profile.d/containerd_env.sh" ]]; then
|
||||||
|
log-wrap 'SourceContainerdEnv' source "/etc/profile.d/containerd_env.sh"
|
||||||
|
fi
|
||||||
|
|
||||||
# Verify presence and print versions of ctr, containerd, runc
|
# Verify presence and print versions of ctr, containerd, runc
|
||||||
if ! command -v ctr >/dev/null 2>&1; then
|
if ! command -v ctr >/dev/null 2>&1; then
|
||||||
echo "ERROR ctr not found. Aborting."
|
echo "ERROR ctr not found. Aborting."
|
||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
ctr --version
|
ctr --version
|
||||||
|
|
||||||
if ! command -v containerd >/dev/null 2>&1; then
|
if ! command -v containerd >/dev/null 2>&1; then
|
||||||
echo "ERROR containerd not found. Aborting."
|
echo "ERROR containerd not found. Aborting."
|
||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
containerd --version
|
containerd --version
|
||||||
|
|
||||||
if ! command -v runc >/dev/null 2>&1; then
|
if ! command -v runc >/dev/null 2>&1; then
|
||||||
echo "ERROR runc not found. Aborting."
|
echo "ERROR runc not found. Aborting."
|
||||||
exit 2
|
exit 2
|
||||||
|
Loading…
Reference in New Issue
Block a user