From 8fd81fb05e84b4dc76dd893df81004ea8988a75f Mon Sep 17 00:00:00 2001 From: Sebastian Serth Date: Thu, 16 Apr 2020 14:52:16 +0200 Subject: [PATCH] Ignore permission problems when deleting files --- lib/docker_client.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/docker_client.rb b/lib/docker_client.rb index e8aeef78..a1d5863a 100644 --- a/lib/docker_client.rb +++ b/lib/docker_client.rb @@ -31,9 +31,9 @@ class DockerClient if local_workspace_path && Pathname.new(local_workspace_path).exist? Pathname.new(local_workspace_path).children.each do |p| p.rmtree - rescue Errno::ENOENT => error + rescue Errno::ENOENT, Errno::EACCES => error Raven.capture_exception(error) - Rails.logger.error('clean_container_workspace: Got Errno::ENOENT: ' + error.to_s) + Rails.logger.error("clean_container_workspace: Got #{error.class.to_s}: #{error.to_s}") end #FileUtils.rmdir(Pathname.new(local_workspace_path)) end