From b25aa52fb9382f1723628bfd2ec1e7e7a6b6ef5c Mon Sep 17 00:00:00 2001 From: Christophe Monniez Date: Mon, 7 Feb 2022 14:18:26 +0100 Subject: [PATCH] [IMP] runbot: avoid core dumps in containers In some conditions, the google-chrome crashes and a core dump is written in the bind mounted directory. With this commit, the core dumps are disabled in the containers. --- runbot/container.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runbot/container.py b/runbot/container.py index 48c122cd..3d98a45d 100644 --- a/runbot/container.py +++ b/runbot/container.py @@ -191,7 +191,7 @@ def _docker_run(cmd=False, log_path=False, build_dir=False, container_name=False for dp, hp in enumerate(exposed_ports, start=8069): ports[f'{dp}/tcp'] = ('127.0.0.1', hp) - ulimits = [] + ulimits = [docker.types.Ulimit(name='core', soft=0, hard=0)] # avoid core dump in containers if cpu_limit: ulimits.append(docker.types.Ulimit(name='cpu', soft=cpu_limit, hard=cpu_limit))