Michal Nasiadka ec358f4cf7 Revert "Fix error when github return 302"
This reverts commit 61def281d077f88051d1b1a14dfdbfabac036c8c.

Reason for revert: --location was already in curlrc and it was unified in change I46b77978926fc2b578a68d1aaa944b2198af0685

Change-Id: I066d747400ede30037ff324ad55430af7c35dc18
2021-03-04 14:51:08 +00:00

38 lines
1.1 KiB
Django/Jinja

FROM {{ namespace }}/{{ infra_image_prefix }}prometheus-base:{{ tag }}
{% block labels %}
LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build_date }}"
{% endblock %}
{% block prometheus_cadvisor_header %}{% endblock %}
{% import "macros.j2" as macros with context %}
{% block prometheus_cadvisor_repository_version %}
ENV prometheus_cadvisor_version=0.35.0
{% endblock %}
{% if base_arch in ['x86_64'] %}
{% block prometheus_cadvisor_install %}
RUN curl -o /opt/cadvisor https://github.com/google/cadvisor/releases/download/v${prometheus_cadvisor_version}/cadvisor && chmod 0755 /opt/cadvisor
{% endblock %}
{% else %}
{% if base_distro in ['debian'] %}
{% set cadvisor_packages = [
'libjs-bootstrap',
'libjs-jquery',
'https://snapshot.debian.org/archive/debian/20180503T060640Z/pool/main/c/cadvisor/cadvisor_0.27.1+dfsg2-1_arm64.deb'
] %}
{{ macros.install_packages(cadvisor_packages | customizable("packages")) }}
RUN ln -s /usr/bin/cadvisor /opt/cadvisor
{% endif %}
{% endif %}
{% block prometheus_cadvisor_footer %}{% endblock %}
{% block footer %}{% endblock %}