From 517e1bc57d0010d142416bd0cfca8cb8b8200939 Mon Sep 17 00:00:00 2001 From: Oscar Reimer Date: Wed, 12 Jun 2024 17:16:15 +0200 Subject: [PATCH] Use Debian noninteractive for less log spam when building image (#241) --- build/docker/debian.Dockerfile | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/build/docker/debian.Dockerfile b/build/docker/debian.Dockerfile index b7a5d34d..4c6324ae 100644 --- a/build/docker/debian.Dockerfile +++ b/build/docker/debian.Dockerfile @@ -1,5 +1,8 @@ FROM golang:1.22-bookworm AS dev WORKDIR /cli + +ARG DEBIAN_FRONTEND=noninteractive + RUN apt -y update && apt -y upgrade && apt -y install git && \ apt -y clean && rm -rf /var/lib/apt/lists/* COPY go.mod go.sum ./ @@ -11,6 +14,9 @@ RUN go build -o debricked ./cmd/debricked CMD [ "debricked" ] FROM debian:bookworm-slim AS cli-base + +ARG DEBIAN_FRONTEND=noninteractive + ENV DEBRICKED_TOKEN="" RUN apt -y update && apt -y upgrade && apt -y install git && \ apt -y clean && rm -rf /var/lib/apt/lists/* @@ -25,6 +31,8 @@ CMD [ "debricked", "scan" ] FROM cli-base AS resolution +ARG DEBIAN_FRONTEND=noninteractive + RUN echo "deb http://deb.debian.org/debian unstable main" >> /etc/apt/sources.list && \ echo "Package: *" >> /etc/apt/preferences && \ echo "Pin: release a=unstable" >> /etc/apt/preferences && \