From ee50dc1a9fdd4b29d9f17d00dc05a0acc19470f2 Mon Sep 17 00:00:00 2001 From: Dan Pock Date: Tue, 10 Dec 2024 15:57:30 -0500 Subject: [PATCH] Make docker files more uniform between HPO and prom-fed --- package/Dockerfile-helm-project-operator | 6 +++--- package/Dockerfile-prometheus-federator | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/package/Dockerfile-helm-project-operator b/package/Dockerfile-helm-project-operator index c7925455..d6ebe9d4 100644 --- a/package/Dockerfile-helm-project-operator +++ b/package/Dockerfile-helm-project-operator @@ -4,7 +4,7 @@ FROM --platform=$BUILDPLATFORM rancher/mirrored-tonistiigi-xx:1.3.0 AS xx FROM --platform=$BUILDPLATFORM registry.suse.com/bci/golang:1.22 AS helm # Clone repository once, and reuse it for target archs. -ARG HELM_VERSION=release-v3.9.0 +ARG HELM_VERSION=v3.13.3-rancher1 ADD --keep-git-dir=true https://github.com/rancher/helm.git#${HELM_VERSION} /helm RUN cd /helm && go mod download @@ -27,17 +27,17 @@ ENV YQ_VERSION=v4.25.1 RUN zypper -n install git curl wget make RUN export ARCH=$(go env GOHOSTARCH) RUN wget https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/yq_linux_${TARGETARCH} -O /usr/bin/yq && chmod +x /usr/bin/yq; -COPY --from=helm /helm/bin/helm /usr/local/bin/ COPY go.mod go.sum ./ RUN go mod download COPY . . -RUN make build +RUN ./scripts/build FROM registry.suse.com/bci/bci-micro:latest RUN echo 'helmprojectoperator:x:1000:1000::/home/helmprojectoperator:/bin/bash' >> /etc/passwd && \ echo 'helmprojectoperator:x:1000:' >> /etc/group && \ mkdir /home/helmprojectoperator && \ chown -R helmprojectoperator:helmprojectoperator /home/helmprojectoperator +COPY --from=helm /helm/bin/helm /usr/local/bin/ COPY --from=builder /usr/src/app/build/bin/helm-project-operator /usr/bin/ USER helmprojectoperator CMD ["helm-project-operator"] diff --git a/package/Dockerfile-prometheus-federator b/package/Dockerfile-prometheus-federator index 2c9dc53f..5e49e9c4 100644 --- a/package/Dockerfile-prometheus-federator +++ b/package/Dockerfile-prometheus-federator @@ -27,7 +27,6 @@ ARG REPO='' ENV EMBEDDED_CHART_VERSION=$EMBEDDED_CHART_VERSION TAG=$TAG REPO=$REPO WORKDIR /usr/src/app -COPY --from=helm ./helm/bin/helm /usr/local/bin/ RUN zypper -n install git vim less file curl wget patch COPY go.mod go.sum ./ RUN go mod download