Skip to content

Commit

Permalink
Adding rpms for EL8 and EL9 and changelog for 0.0.6 and 0.0.7 (#53)
Browse files Browse the repository at this point in the history
* Improving rpm build script and adding support for EL8 and EL9

* Adding release 0.0.7
  • Loading branch information
guilbaults committed Dec 12, 2023
1 parent 22342f2 commit 12e7b2d
Show file tree
Hide file tree
Showing 7 changed files with 151 additions and 24 deletions.
20 changes: 0 additions & 20 deletions .github/workflows/rpm.yml

This file was deleted.

25 changes: 25 additions & 0 deletions .github/workflows/rpm_centos7.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: RPM Build centos7
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Package RPM and SRPM
uses: guilbaults/rpm-package-action@centos
with:
path: .
spec: infiniband-exporter-el7.spec
distro: centos-7

- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: output/*
25 changes: 25 additions & 0 deletions .github/workflows/rpm_rocky8.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: RPM Build rocky8
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Package RPM and SRPM
uses: xmidt-org/rpm-package-action@v1
with:
path: .
spec: infiniband-exporter-el8.spec
distro: rocky-8

- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: output/*
25 changes: 25 additions & 0 deletions .github/workflows/rpm_rocky9.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: RPM Build rocky9
on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Package RPM and SRPM
uses: guilbaults/rpm-package-action@centos
with:
path: .
spec: infiniband-exporter-el9.spec
distro: rocky-9

- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: output/*
8 changes: 6 additions & 2 deletions infiniband-exporter-el7.spec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Name: infiniband-exporter
Version: 0.0.6
%global gittag 0.0.6
Version: 0.0.7
%global gittag 0.0.7
Release: 1%{?dist}
Summary: Prometheus exporter for a Infiniband Fabric

Expand Down Expand Up @@ -45,6 +45,10 @@ rm -rf $RPM_BUILD_ROOT
%{_unitdir}/infiniband-exporter.service

%changelog
* Tue Dec 12 2023 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.7-1
- Building RPM for EL9
* Thu Jan 21 2022 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.6-1
- Adding PortXmitConstraintErrors, PortMalformedPktErrors and PortSwLifetimeLimitDiscards
* Mon Nov 22 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.5-1
- Implement PortSwHOQLifetimeLimitDiscards metric
* Mon Aug 02 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.4-1
Expand Down
64 changes: 64 additions & 0 deletions infiniband-exporter-el8.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
Name: infiniband-exporter
Version: 0.0.7
%global gittag 0.0.7
Release: 1%{?dist}
Summary: Prometheus exporter for a Infiniband Fabric

License: Apache License 2.0
URL: https://github.com/guilbaults/infiniband-exporter
Source0: https://github.com/guilbaults/%{name}/archive/v%{gittag}/%{name}-%{version}.tar.gz

BuildArch: noarch
BuildRequires: systemd
Requires: python3
Requires: infiniband-diags

%description
Prometheus exporter for a Infiniband fabric. This exporter only need to be installed on one server connected to the fabric, it will collect all the ports statistics on all the switches.

Metrics are identified by type, port number, switch GUID and name. The remote connection of each port is also collected. Thus each metric represents a cable between 2 switches, or between a switch and a card in a server.

When a node name map file is provided, it will be used by ibquerryerror to put a more human friendly name on switches.

This exporter takes 3 seconds to collect the information of 60+ IB switches, and 900+ compute nodes. The information takes about 7.5MB in ASCII format for that fabric.

%prep
%autosetup -n %{name}-%{gittag}
%setup -q

%build

%install
mkdir -p %{buildroot}/%{_bindir}
mkdir -p %{buildroot}/%{_unitdir}

install -m 0755 %{name}.py %{buildroot}/%{_bindir}/%{name}
install -m 0644 infiniband-exporter.service %{buildroot}/%{_unitdir}/infiniband-exporter.service

%clean
rm -rf $RPM_BUILD_ROOT

%files
%{_bindir}/%{name}
%{_unitdir}/infiniband-exporter.service

%changelog
* Tue Dec 12 2023 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.7-1
- Building RPM for EL9
* Thu Jan 21 2022 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.6-1
- Adding PortXmitConstraintErrors, PortMalformedPktErrors and PortSwLifetimeLimitDiscards
* Mon Nov 22 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.5-1
- Implement PortSwHOQLifetimeLimitDiscards metric
* Mon Aug 02 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.4-1
- Deprecated python2
- Adding client HCA stats
- Adding scrape errors handling
* Fri Apr 09 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.3-1
- Adding ca_name option
- Adding a real logging output instead of print()
- Adding scrape duration and status
- Detect when ibqueryerrors is not executable
* Mon Mar 30 2020 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.2-1
- Fixing counter reset using python subprocess.Popen()
* Fri Mar 20 2020 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.1-1
- Initial release
8 changes: 6 additions & 2 deletions infiniband-exporter-el9.spec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Name: infiniband-exporter
Version: 0.0.6
%global gittag 0.0.6
Version: 0.0.7
%global gittag 0.0.7
Release: 1%{?dist}
Summary: Prometheus exporter for a Infiniband Fabric

Expand Down Expand Up @@ -44,6 +44,10 @@ rm -rf $RPM_BUILD_ROOT
%{_unitdir}/infiniband-exporter.service

%changelog
* Tue Dec 12 2023 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.7-1
- Building RPM for EL9
* Thu Jan 21 2022 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.6-1
- Adding PortXmitConstraintErrors, PortMalformedPktErrors and PortSwLifetimeLimitDiscards
* Mon Nov 22 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.5-1
- Implement PortSwHOQLifetimeLimitDiscards metric
* Mon Aug 02 2021 Simon Guilbault <simon.guilbault@calculquebec.ca> 0.0.4-1
Expand Down

0 comments on commit 12e7b2d

Please sign in to comment.