From 2a95a72e5bd24df53423a2010cc147b574de928a Mon Sep 17 00:00:00 2001 From: Duncan Harvey Date: Mon, 1 Dec 2025 12:35:13 -0500 Subject: [PATCH] run apt-get update and apt-get install in same layer --- scripts/Dockerfile.alpine.build | 3 +-- scripts/Dockerfile.build | 3 +-- scripts/Dockerfile.race.build | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/scripts/Dockerfile.alpine.build b/scripts/Dockerfile.alpine.build index b675880a8..d5b86743f 100644 --- a/scripts/Dockerfile.alpine.build +++ b/scripts/Dockerfile.alpine.build @@ -54,8 +54,7 @@ RUN /usr/lib/go/bin/go tool nm datadog-agent | grep -w 'github.com/DataDog/datad FROM ubuntu:22.04 as compresser ARG CMD_PATH ARG DATADOG_WRAPPER=datadog_wrapper -RUN apt-get update -RUN apt-get install -y zip binutils +RUN apt-get update && apt-get install -y zip binutils RUN mkdir /extensions WORKDIR /extensions COPY --from=builder /tmp/dd/datadog-agent/"${CMD_PATH}"/datadog-agent /extensions/datadog-agent diff --git a/scripts/Dockerfile.build b/scripts/Dockerfile.build index 95423f252..8b98dad5a 100644 --- a/scripts/Dockerfile.build +++ b/scripts/Dockerfile.build @@ -57,8 +57,7 @@ FROM ubuntu:22.04 as compresser ARG CMD_PATH ARG DATADOG_WRAPPER=datadog_wrapper -RUN apt-get update -RUN apt-get install -y zip binutils +RUN apt-get update && apt-get install -y zip binutils RUN mkdir /extensions WORKDIR /extensions COPY --from=builder /tmp/dd/datadog-agent/"${CMD_PATH}"/datadog-agent /extensions/datadog-agent diff --git a/scripts/Dockerfile.race.build b/scripts/Dockerfile.race.build index 58e9e7055..65eeed6bb 100644 --- a/scripts/Dockerfile.race.build +++ b/scripts/Dockerfile.race.build @@ -43,8 +43,7 @@ RUN go tool nm datadog-agent | grep -w 'github.com/DataDog/datadog-agent/pkg/ver # zip the extension FROM ubuntu:22.04 as compresser -RUN apt-get update -RUN apt-get install -y zip +RUN apt-get update && apt-get install -y zip RUN mkdir /extensions WORKDIR /extensions COPY --from=builder /tmp/dd/datadog-agent/cmd/serverless/datadog-agent /extensions/datadog-agent