-
Notifications
You must be signed in to change notification settings - Fork 7
/
Dockerfile.thanos
35 lines (27 loc) · 1.27 KB
/
Dockerfile.thanos
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_8_golang_1.22 as builder
WORKDIR /workspace
COPY thanos .
ENV GOFLAGS='-mod=mod'
ENV CGO_ENABLED=0
# Install promu and build thanos
ARG TARGETOS TARGETARCH
RUN wget https://github.com/prometheus/promu/releases/download/v0.17.0/promu-0.17.0.${TARGETOS}-${TARGETARCH}.tar.gz \
&& tar -xzf promu-0.17.0.${TARGETOS}-${TARGETARCH}.tar.gz -C /usr/local/bin \
&& rm promu-0.17.0.${TARGETOS}-${TARGETARCH}.tar.gz \
&& /usr/local/bin/promu-0.17.0.${TARGETOS}-${TARGETARCH}/promu -v build --prefix /go/bin/
FROM registry.redhat.io/ubi8/ubi-minimal:8.10-1130
WORKDIR /
COPY --from=builder /go/bin/thanos /bin/thanos
COPY --from=builder /workspace/LICENSE /licenses/.
USER nobody
ENTRYPOINT [ "/bin/thanos" ]
LABEL com.redhat.component="coo-thanos-container" \
name="rhobs/thanos" \
version="v0.36.1" \
summary="Thanos for Cluster Observability Operator" \
io.openshift.expose-services="" \
io.openshift.tags="monitoring" \
io.k8s.display-name="COO Thanos" \
io.k8s.description="Thanos extends Prometheus with highly available, scalable and unlimited metric storage." \
maintainer="[email protected]" \
description="Thanos for Cluster Observability Operator"