-
Notifications
You must be signed in to change notification settings - Fork 8
/
Dockerfile.alertmanager
43 lines (33 loc) · 1.45 KB
/
Dockerfile.alertmanager
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
36
37
38
39
40
41
42
43
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_8_golang_1.22 AS builder
RUN dnf module install -y nodejs:16/development
ENV NPM_CONFIG_NODEDIR=/usr
ENV GOFLAGS='-mod=mod'
WORKDIR /workspace
# Copy source files
COPY alertmanager/ .
# Build
ENV NO_DOCKER=true
RUN make build
FROM registry.redhat.io/ubi8/ubi-minimal:8.10-1130
COPY --from=builder workspace/amtool /bin/amtool
COPY --from=builder workspace/alertmanager /bin/alertmanager
COPY --from=builder workspace/examples/ha/alertmanager.yml /etc/alertmanager/alertmanager.yml
COPY --from=builder workspace/LICENSE /licenses/.
RUN mkdir -p /alertmanager && \
chown -R nobody:nobody etc/alertmanager /alertmanager
USER nobody
EXPOSE 9093
VOLUME [ "/alertmanager" ]
WORKDIR /alertmanager
ENTRYPOINT [ "/bin/alertmanager" ]
CMD [ "--config.file=/etc/alertmanager/alertmanager.yml", \
"--storage.path=/alertmanager" ]
LABEL com.redhat.component="coo-alertmanager" \
name="Alertmanager" \
version="v0.27.0" \
summary="Alertmanager for Cluster Observability Operator" \
io.openshift.tags="openshift,monitoring" \
io.k8s.display-name="Alertmanager" \
io.k8s.description="Alertmanager handles alerts sent by client applications such as the Prometheus server" \
maintainer="OpenShift Monitoring team <[email protected]>" \
description="Alertmanager for Cluster Observability Operator" \