From ed40e6e3dcb35adfd5df4b4bbba65ebdadabb55a Mon Sep 17 00:00:00 2001
From: Rhys Arkins <rhys@arkins.net>
Date: Thu, 30 Apr 2020 17:18:50 +0200
Subject: [PATCH] =?UTF-8?q?fix:=20don=E2=80=99t=20warn=20if=20can=E2=80=99?=
 =?UTF-8?q?t=20connect=20to=20the=20Docker=20deamon?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Closes #6094
---
 lib/util/exec/docker/index.ts | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/lib/util/exec/docker/index.ts b/lib/util/exec/docker/index.ts
index b0fa2c23dd..0c488bfb71 100644
--- a/lib/util/exec/docker/index.ts
+++ b/lib/util/exec/docker/index.ts
@@ -159,11 +159,13 @@ export async function removeDanglingContainers(): Promise<void> {
     } else {
       logger.debug('No dangling containers to remove');
     }
-  } catch (err) {
-    // istanbul ignore if
+  } catch (err) /* istanbul ignore next */ {
     if (err.errno === 'ENOMEM') {
       throw new Error(SYSTEM_INSUFFICIENT_MEMORY);
     }
+    if (err.stderr?.includes('Cannot connect to the Docker daemon')) {
+      logger.info('No docker deamon found');
+    }
     logger.warn({ err }, 'Error removing dangling containers');
   }
 }
-- 
GitLab