From 37af982691e380e0e74010f66ebabe17c41f7ae6 Mon Sep 17 00:00:00 2001 From: maxime mouial Date: Thu, 5 Dec 2024 17:45:23 +0100 Subject: [PATCH] Conditionally set GOFIPS env var (#31781) Co-authored-by: dustmop --- Dockerfiles/agent/Dockerfile | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Dockerfiles/agent/Dockerfile b/Dockerfiles/agent/Dockerfile index 6c8cb42eedccf..58ecd02ae3bb6 100644 --- a/Dockerfiles/agent/Dockerfile +++ b/Dockerfiles/agent/Dockerfile @@ -183,9 +183,8 @@ RUN [ "$(getent passwd dd-agent | cut -d: -f 3)" -eq 100 ] # Enable FIPS if needed RUN if [ -x /opt/datadog-agent/embedded/bin/fipsinstall.sh ]; then \ /opt/datadog-agent/embedded/bin/fipsinstall.sh; \ + export GOFIPS=1; \ fi -# This is used by MSGO to enable FIPS mode so it won't affect the non-FIPS image -ENV GOFIPS=1 # Override the exit script by ours to fix --pid=host operations RUN mv /etc/s6/init/init-stage3 /etc/s6/init/init-stage3-original