From 80085ba018e685476476f03ea9d8325011c66769 Mon Sep 17 00:00:00 2001 From: Tim Wojtulewicz Date: Thu, 12 Oct 2023 15:00:52 -0700 Subject: [PATCH] CI: Add more logging during docker builds (cherry picked from commit 3d1380305beaf2e48e22444a285e1f64e4d120d0) --- .cirrus.yml | 1 + docker/builder.Dockerfile | 5 +++++ docker/final.Dockerfile | 5 +++++ 3 files changed, 11 insertions(+) diff --git a/.cirrus.yml b/.cirrus.yml index 739d4feca6..0b334b7955 100644 --- a/.cirrus.yml +++ b/.cirrus.yml @@ -437,6 +437,7 @@ docker_build_template: &DOCKER_BUILD_TEMPLATE CIRRUS_LOG_TIMESTAMP: true BUILDER_IMAGE_CACHE_DIR: /tmp/builder-image-cache ZEEK_IMAGE_CACHE_DIR: /tmp/zeek-image-cache-${CIRRUS_ARCH} + BUILDKIT_PROGRESS: plain always: ccache_cache: diff --git a/docker/builder.Dockerfile b/docker/builder.Dockerfile index 0c1685ac2e..662f3ef3e7 100644 --- a/docker/builder.Dockerfile +++ b/docker/builder.Dockerfile @@ -3,6 +3,11 @@ # Layer to build Zeek. FROM debian:bookworm-slim +# Make the shell split commands in the log so we can determine reasons for +# failures more easily. +SHELL ["/bin/sh", "-x", "-c"] + +# Allow apt to retry 3 times before failing. RUN echo 'Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries # Configure system for build. diff --git a/docker/final.Dockerfile b/docker/final.Dockerfile index 97e4d80599..eeab916a93 100644 --- a/docker/final.Dockerfile +++ b/docker/final.Dockerfile @@ -3,6 +3,11 @@ # Final layer containing all artifacts. FROM debian:bookworm-slim +# Make the shell split commands in the log so we can determine reasons for +# failures more easily. +SHELL ["/bin/sh", "-x", "-c"] + +# Allow apt to retry 3 times before failing. RUN echo 'Acquire::Retries "3";' > /etc/apt/apt.conf.d/80-retries RUN apt-get -q update \