Skip to content

Commit

Permalink
Merge pull request #146 from stackhpc/upstream/xena-2022-07-04
Browse files Browse the repository at this point in the history
Synchronise xena with upstream
  • Loading branch information
priteau authored Jul 8, 2022
2 parents 10688e9 + ea1d216 commit 0c8ff7c
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 27 deletions.
34 changes: 7 additions & 27 deletions docker/prometheus/prometheus-openstack-exporter/Dockerfile.j2
Original file line number Diff line number Diff line change
Expand Up @@ -7,36 +7,16 @@ LABEL maintainer="{{ maintainer }}" name="{{ image_name }}" build-date="{{ build

{% block prometheus_openstack_exporter_header %}{% endblock %}

{% if base_package_type == 'rpm' %}
{% set prometheus_openstack_exporter_packages = [
'git',
'go',
'make',
] %}
{% elif base_package_type == 'deb' %}
{% set prometheus_openstack_exporter_packages = [
'build-essential',
'git',
'golang-go',
] %}
{% endif %}

{{ macros.install_packages(prometheus_openstack_exporter_packages | customizable("packages")) }}
{% block prometheus_openstack_exporter_repository_version %}
ARG prometheus_openstack_exporter_version=1.6.0
ARG prometheus_openstack_exporter_url=https://github.com/openstack-exporter/openstack-exporter/releases/download/v${prometheus_openstack_exporter_version}/openstack-exporter_${prometheus_openstack_exporter_version}_linux_{{debian_arch}}.tar.gz
{% endblock %}

{% block prometheus_openstack_exporter_install %}
ARG prometheus_openstack_exporter_url=https://github.com/stackhpc/openstack-exporter/archive/refs/heads
ARG prometheus_openstack_exporter_version=project-parent-id
ENV GOPATH=/build
RUN mkdir /build \
&& cd /build \
&& curl -o openstack-exporter.tar.gz ${prometheus_openstack_exporter_url}/${prometheus_openstack_exporter_version}.tar.gz \
&& tar xvf openstack-exporter.tar.gz \
&& cd openstack-exporter-${prometheus_openstack_exporter_version} \
&& make common-build \
&& mv openstack-exporter-${prometheus_openstack_exporter_version} openstack-exporter \
RUN curl -o /tmp/prometheus_openstack_exporter.tar.gz ${prometheus_openstack_exporter_url} \
&& mkdir /opt/openstack-exporter \
&& install -m 0755 openstack-exporter /opt/openstack-exporter/ \
&& rm -rf /build
&& tar xvf /tmp/prometheus_openstack_exporter.tar.gz -C /opt/openstack-exporter \
&& rm -f /tmp/prometheus_openstack_exporter.tar.gz
{% endblock %}

{% block prometheus_openstack_exporter_footer %}{% endblock %}
Expand Down
11 changes: 11 additions & 0 deletions releasenotes/notes/openstack-exporter-1.6.0-cb2c1a978cf4be64.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
features:
- |
Updates the OpenStack exporter for Prometheus to `version 1.6.0
<https://github.com/openstack-exporter/openstack-exporter/releases/tag/v1.6.0>`__.
upgrade:
- |
The updated OpenStack exporter for Prometheus uses the latest Nova API
microversion by default, resulting in changes to existing metrics. To keep
existing behaviour, set
``prometheus_openstack_exporter_compute_api_version`` to ``2.1``.

0 comments on commit 0c8ff7c

Please sign in to comment.