runtime-rs: fix typo get_contaier_type to get_container_type

Change get_contaier_type to get_container_type

Fixes: #5415

Signed-off-by: Bin Liu <bin@hyper.sh>
This commit is contained in:
Bin Liu
2022-10-13 17:12:43 +08:00
parent 2de29b6f69
commit 4d9dd8790d
2 changed files with 4 additions and 4 deletions

View File

@@ -6,7 +6,7 @@
use anyhow::{Context, Result};
use containerd_shim_protos::api;
use kata_sys_util::spec::{get_bundle_path, get_contaier_type, load_oci_spec};
use kata_sys_util::spec::{get_bundle_path, get_container_type, load_oci_spec};
use kata_types::container::ContainerType;
use nix::{sys::signal::kill, sys::signal::SIGKILL, unistd::Pid};
use protobuf::Message;
@@ -53,7 +53,7 @@ impl ShimExecutor {
let bundle_path = get_bundle_path().context("get bundle path")?;
if let Ok(spec) = load_oci_spec() {
if let Ok(ContainerType::PodSandbox) = get_contaier_type(&spec) {
if let Ok(ContainerType::PodSandbox) = get_container_type(&spec) {
// only force shutdown for sandbox container
if let Ok(shim_pid) = self.read_pid_file(&bundle_path) {
info!(sl!(), "force to shutdown shim process {}", shim_pid);