cbbceb0ad3
Add container for prometheus, mysqld_exporter, node_exporter and haproxy_exporter Change-Id: I6e4eb0391380e594b708a67365e240d3eeafd88b
22 lines
819 B
Django/Jinja
22 lines
819 B
Django/Jinja
FROM {{ namespace }}/{{ image_prefix }}prometheus-base:{{ tag }}
|
|
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
|
|
|
|
{% block prometheus_server_header %}{% endblock %}
|
|
|
|
{% block prometheus_server_repository_version %}
|
|
ENV prometheus_version=1.7.1
|
|
{% endblock %}
|
|
|
|
{% block prometheus_server_install %}
|
|
RUN curl -sSL -o /tmp/prometheus.tar.gz https://github.com/prometheus/prometheus/releases/download/v${prometheus_version}/prometheus-${prometheus_version}.linux-${prometheus_arch}.tar.gz \
|
|
&& tar xvf /tmp/prometheus.tar.gz -C /opt/ \
|
|
&& rm -f /tmp/prometheus.tar.gz \
|
|
&& ln -s /opt/prometheus* /opt/prometheus \
|
|
&& mkdir -p /etc/prometheus /data
|
|
{% endblock %}
|
|
|
|
{% block prometheus_server_footer %}{% endblock %}
|
|
{% block footer %}{% endblock %}
|
|
|
|
USER prometheus
|