## START: Set by rpmautospec ## (rpmautospec version 0.7.3) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %bcond_without check %bcond_without bundled %if 0%{?rhel} %bcond_without bundled %endif %if %{defined rhel} && 0%{?rhel} < 10 %define gobuild(o:) go build -buildmode pie -compiler gc -tags="rpm_crashtraceback ${BUILDTAGS:-}" -ldflags "-linkmode=external -compressdwarf=false ${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \\n') -extldflags '%__global_ldflags'" -a -v -x %{?**}; %endif %if %{with bundled} %global gomodulesmode GO111MODULE=on %endif # https://github.com/containers/prometheus-podman-exporter %global goipath github.com/containers/prometheus-podman-exporter Version: 1.14.0 %gometa -f %global goname prometheus-podman-exporter %global common_description %{expand: Prometheus exporter for podman environments exposing containers, pods, images, volumes and networks information.} %global golicenses LICENSE %global godocs CODE_OF_CONDUCT.md CONTRIBUTING.md MAINTAINERS.md\\\ README.md SECURITY.md Name: %{goname} Release: %autorelease Summary: Prometheus exporter for podman environment License: Apache-2.0 AND MPL-2.0 AND BSD-3-Clause AND BSD-2-Clause AND MIT AND Unlicense AND CC-BY-SA-4.0 AND ISC URL: %{gourl} Source: %{gosource} Source: vendor-%{version}.tar.gz Source: bundle_go_deps_for_rpm.sh %if 0%{?fedora} && ! 0%{?rhel} BuildRequires: pkgconfig(libbtrfsutil) %endif BuildRequires: gcc BuildRequires: glibc-devel BuildRequires: glibc-static BuildRequires: git-core %if 0%{?rhel} >= 9 BuildRequires: go-rpm-macros %endif BuildRequires: golang BuildRequires: make BuildRequires: pkgconfig(devmapper) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(gpgme) BuildRequires: pkgconfig(libassuan) %if 0%{?fedora} >= 37 BuildRequires: shadow-utils-subid-devel %endif %description %{common_description} %prep %goprep %{?with_bundledc:-k} %if %{with bundled} %setup -q -T -D -a 1 -n %{name}-%{version} %endif %if %{without bundled} %generate_buildrequires %go_generate_buildrequires %endif %build %if %{with bundled} export GOFLAGS="-mod=vendor" %endif %if 0%{?rhel} >= 9 export BUILDTAGS="exclude_graphdriver_btrfs btrfs_noversion systemd libtrust_openssl" %endif %if 0%{?fedora} export BUILDTAGS="systemd" %endif export LDFLAGS="-X %{goipath}/cmd.buildVersion=%{version} -X %{goipath}/cmd.buildRevision=%{release} -X %{goipath}/cmd.buildBranch=main" %gobuild -o %{gobuilddir}/bin/prometheus-podman-exporter %{goipath} %install install -m 0755 -vd %{buildroot}%{_bindir} install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ install -m 0755 -vd %{buildroot}%{_unitdir} install -m 0755 -vd %{buildroot}%{_userunitdir} install -m 0755 -vd %{buildroot}%{_sysconfdir}/sysconfig/ install -m 0644 -vp ./contrib/systemd/system/%{name}.sysconfig %{buildroot}%{_sysconfdir}/sysconfig/%{name} install -m 0644 -vp ./contrib/systemd/system/%{name}.service %{buildroot}%{_unitdir}/%{name}.service install -m 0644 -vp ./contrib/systemd/user/%{name}.service %{buildroot}%{_userunitdir}/%{name}.service %post %systemd_user_post %{name}.service %systemd_post %{name}.service %preun %systemd_user_preun %{name}.service %systemd_preun %{name}.service %if %{with check} %check %endif %files %license LICENSE %doc CODE_OF_CONDUCT.md CONTRIBUTING.md MAINTAINERS.md README.md SECURITY.md %{_bindir}/%{name} %{_sysconfdir}/sysconfig/%{name} %{_unitdir}/%{name}.service %{_userunitdir}/%{name}.service %changelog ## START: Generated by rpmautospec * Sat Dec 14 2024 Navid Yaghoobi - 1.14.0-1 - release v1.14.0 * Sat Oct 19 2024 Navid Yaghoobi - 1.13.3-1 - release v1.13.3 * Fri Sep 27 2024 Navid Yaghoobi - 1.13.2-1 - release v1.13.2 * Sat Aug 24 2024 Navid Yaghoobi - 1.13.1-1 - release v1.13.1 * Sat Aug 03 2024 Navid Yaghoobi - 1.13.0-1 - release v1.13.0 * Fri Jul 19 2024 Fedora Release Engineering - 1.12.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild * Wed Jun 26 2024 Yaakov Selkowitz - 1.12.0-2 - Use go-rpm-macros on RHEL 10+ * Sun Jun 02 2024 Navid Yaghoobi - 1.12.0-1 - release v1.12.0 * Sun May 12 2024 Navid Yaghoobi - 1.11.1-1 - release v1.11.1 * Fri Mar 22 2024 Navid Yaghoobi - 1.11.0-1 - release v1.11.0 * Sun Mar 17 2024 Navid Yaghoobi - 1.10.1-1 - release v1.10.1 * Sat Mar 16 2024 Navid Yaghoobi - 1.10.0-1 - release v1.10.0 * Thu Feb 29 2024 Navid Yaghoobi - 1.9.0-1 - release v1.9.0 * Sun Feb 11 2024 Maxwell G - 1.8.0-2 - Rebuild for golang 1.22.0 * Sun Feb 04 2024 Navid Yaghoobi - 1.8.0-1 - release v1.8.0 * Fri Jan 26 2024 Fedora Release Engineering - 1.7.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild * Sun Jan 21 2024 Navid Yaghoobi - 1.7.0-1 - release v1.7.0 * Fri Dec 01 2023 Navid Yaghoobi - 1.6.0-1 - release v1.6.0 * Sat Nov 11 2023 Navid Yaghoobi - 1.5.0-1 - release v1.5.0 * Fri Oct 20 2023 Navid Yaghoobi - 1.4.0-1 - Initial import (fedora#2240313) ## END: Generated by rpmautospec