summaryrefslogtreecommitdiff
path: root/libpod/oci_conmon_linux.go
diff options
context:
space:
mode:
authorAditya Rajan <arajan@redhat.com>2021-11-23 16:41:23 +0530
committerAditya Rajan <arajan@redhat.com>2021-11-23 16:41:28 +0530
commita4e4b8d9269761efd97848b4c88f092f9cfd497b (patch)
tree06ffc63267dd11f60f9d2c48547283c8b50c6961 /libpod/oci_conmon_linux.go
parent08558b27ffcd9e1fa6d4d31536e41c9acabebb25 (diff)
downloadpodman-a4e4b8d9269761efd97848b4c88f092f9cfd497b.tar.gz
podman-a4e4b8d9269761efd97848b4c88f092f9cfd497b.tar.bz2
podman-a4e4b8d9269761efd97848b4c88f092f9cfd497b.zip
oci: ack crun output when container is not there
`crun status ctrid` outputs `No such file or directory` when container is not there so podman much ack it. [NO NEW TESTS NEEDED] Signed-off-by: Aditya Rajan <arajan@redhat.com>
Diffstat (limited to 'libpod/oci_conmon_linux.go')
-rw-r--r--libpod/oci_conmon_linux.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/libpod/oci_conmon_linux.go b/libpod/oci_conmon_linux.go
index dee9634e1..ea6facfa6 100644
--- a/libpod/oci_conmon_linux.go
+++ b/libpod/oci_conmon_linux.go
@@ -297,7 +297,7 @@ func (r *ConmonOCIRuntime) UpdateContainerStatus(ctr *Container) error {
if err2 != nil {
return errors.Wrapf(err, "error getting container %s state", ctr.ID())
}
- if strings.Contains(string(out), "does not exist") {
+ if strings.Contains(string(out), "does not exist") || strings.Contains(string(out), "No such file") {
if err := ctr.removeConmonFiles(); err != nil {
logrus.Debugf("unable to remove conmon files for container %s", ctr.ID())
}