mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-25 15:02:45 +00:00
Merge pull request #999 from wilsonianb/fix-k3s
kata-deploy: fix k3s containerd check
This commit is contained in:
commit
dce8d66a30
@ -33,7 +33,7 @@ function print_usage() {
|
||||
|
||||
function get_container_runtime() {
|
||||
|
||||
local runtime=$(kubectl get node $NODE_NAME -o jsonpath='{.status.nodeInfo.containerRuntimeVersion}' | awk -F '[:]' '{print $1}')
|
||||
local runtime=$(kubectl get node $NODE_NAME -o jsonpath='{.status.nodeInfo.containerRuntimeVersion}')
|
||||
if [ "$?" -ne 0 ]; then
|
||||
die "invalid node name"
|
||||
fi
|
||||
@ -44,7 +44,7 @@ function get_container_runtime() {
|
||||
echo "k3s"
|
||||
fi
|
||||
else
|
||||
echo "$runtime"
|
||||
echo "$runtime" | awk -F '[:]' '{print $1}'
|
||||
fi
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user