Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Debian noninteractive for less log spam when building image #241

Merged
merged 1 commit into from
Jun 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions build/docker/debian.Dockerfile
Original file line number Diff line number Diff line change
@@ -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 ./
Expand All @@ -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/*
Expand All @@ -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 && \
Expand Down
Loading