forked from prometheus/alertmanager
-
Notifications
You must be signed in to change notification settings - Fork 19
/
Dockerfile.ocp
23 lines (20 loc) · 1.11 KB
/
Dockerfile.ocp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# FROM directives are overriden by CI system (both Prow CI and OSBS)
FROM registry.svc.ci.openshift.org/openshift/release:golang-1.12 AS builder
WORKDIR /go/src/github.com/prometheus/alertmanager
COPY . .
RUN if yum install -y prometheus-promu; then export BUILD_PROMU=false; fi && make build
FROM registry.svc.ci.openshift.org/openshift/origin-v4.0:base
LABEL io.k8s.display-name="OpenShift Prometheus Alert Manager" \
io.k8s.description="Prometheus Alert Manager" \
io.openshift.tags="prometheus,monitoring" \
maintainer="OpenShift Development <dev@lists.openshift.redhat.com>"
ARG ALERTMANAGER_GOPATH=/go/src/github.com/prometheus/alertmanager
COPY --from=builder ${ALERTMANAGER_GOPATH}/amtool /bin/amtool
COPY --from=builder ${ALERTMANAGER_GOPATH}/alertmanager /bin/alertmanager
COPY --from=builder ${ALERTMANAGER_GOPATH}/examples/ha/alertmanager.yml /etc/alertmanager/alertmanager.yml
EXPOSE 9093
RUN mkdir -p /alertmanager
VOLUME [ "/alertmanager" ]
WORKDIR /etc/alertmanager
ENTRYPOINT [ "/bin/alertmanager" ]
CMD [ "--storage.path=/alertmanager" ]