mirror of
https://github.com/Telecominfraproject/openafc_final.git
synced 2026-01-27 02:22:02 +00:00
44 lines
1.4 KiB
Plaintext
44 lines
1.4 KiB
Plaintext
#
|
|
# Copyright (C) 2021 Broadcom. All rights reserved. The term "Broadcom"
|
|
# refers solely to the Broadcom Inc. corporate affiliate that owns
|
|
# the software below. This work is licensed under the OpenAFC Project License,
|
|
# a copy of which is included with this software program
|
|
#
|
|
|
|
FROM ubuntu/prometheus:2.46.0-22.04_stable
|
|
|
|
# Database directory. May be mapped to something external for persistence.
|
|
# Evaluated in entrypoint.sh (i.e. not baked-in)
|
|
ENV PROMETHEUS_DATA=/prometheus/data
|
|
|
|
# Scrape interval. Must have unit suffix (e.g. 15s for 15 seconds, 1m for one
|
|
# minute, etc.) By default taken from prometheus.yml (5 seconds as of time of
|
|
# this writing)
|
|
# ENV PROMETHEUS_SCRAPE_INTERVAL
|
|
|
|
# Scrape timeout. Must be smaller than scrape interval. Must have unit suffix
|
|
# (e.g. 10s for 10 seconds, 1m for one minute, etc.) By default taken from
|
|
# prometheus.yml (2 seconds as of time of this writing)
|
|
# ENV PROMETHEUS_SCRAPE_TIMEOUT
|
|
|
|
# PERSISTING PROMETHEUS DATA
|
|
# Prometheus database is at /prometheus/data inside the container. It can be'
|
|
# persisted if mapped to some external directory
|
|
|
|
RUN apt update
|
|
RUN apt upgrade -y
|
|
RUN apt install -y curl
|
|
|
|
WORKDIR /prometheus
|
|
|
|
COPY prometheus.yml /prometheus/
|
|
COPY prometheus_entrypoint.sh /prometheus
|
|
RUN chmod +x /prometheus/prometheus_entrypoint.sh
|
|
|
|
EXPOSE 9090/TCP
|
|
|
|
ENTRYPOINT ["./prometheus_entrypoint.sh"]
|
|
|
|
HEALTHCHECK CMD curl --fail http://localhost:9090/-/healthy || exit 1
|
|
|