@@ -70,16 +70,6 @@ _PCP_RPMS = \
7070 pcp-system-tools \
7171 pcp-zeroconf
7272
73- # These are the lists of Prometheus RPMs -- the packages are the same, but they
74- # have different names in the different distributions -- so we have two lists
75- # keyed by the distro name.
76- _centos_PROMETHEUS_RPMS = \
77- node_exporter \
78- prometheus2
79- _fedora_PROMETHEUS_RPMS = \
80- golang-github-prometheus-node-exporter \
81- golang-github-prometheus
82-
8373# The list of RPMs which provide the various tools we offer.
8474# Not intended to be overridden with an environment variable.
8575# Please keep the lists sorted.
@@ -96,7 +86,7 @@ _TOOL_RPMS = \
9686 ${_PCP_RPMS} \
9787 perf \
9888 procps-ng \
99- ${_${DIST_NAME} _PROMETHEUS_RPMS} \
89+ ${_PROMETHEUS_RPMS} \
10090 strace \
10191 tcpdump \
10292 trace-cmd
@@ -154,6 +144,15 @@ $(_DISTROS:%=%-tm): %-tm: pkgmgr-clean %-tool-meister-tagged
154144% : DIST_NAME = $(wordlist 1, 1, $(subst -, ,$* ) )
155145% : DIST_VERSION = $(wordlist 2, 2, $(subst -, ,$* ) )
156146
147+ # These are the lists of Prometheus RPMs -- the packages are the same, but they
148+ # have different names in the different distributions
149+ fedora-% centos-9-% : _PROMETHEUS_RPMS = \
150+ golang-github-prometheus-node-exporter \
151+ golang-github-prometheus
152+ centos-7-% centos-8-% : _PROMETHEUS_RPMS = \
153+ node_exporter \
154+ prometheus2
155+
157156
158157# Tagging targets
159158#
@@ -212,11 +211,13 @@ $(_TAG_TYPES:%=push-%): push-%: $(_DEFAULT_DISTROS:%=%-push-%)
212211% -tools-tagged : % -tools % -tags.lis
213212 ./apply-tags pbench-agent-tools-$* $* -tags.lis
214213
215- # Add an additional dependency for centos-%-tools targets (this .repo file is
216- # not required on Fedora).
217- $(_ALL_centos_VERSIONS:% =%-tools): centos-%-tools: centos-%-prometheus.repo
214+ # CentOS 7 & 8 (but not 9) require an additional .repo file for Prometheus for
215+ # the tools container; analogously, they as well as Fedora require an additional
216+ # .repo file for PCP.
217+ centos-7-tools centos-8-tools : centos-% -tools: centos-% -prometheus.repo
218+ $(_ALL_fedora_VERSIONS:% =%-tools) centos-7-tools centos-8-tools: %-tools: %-pcp.repo
218219
219- % -tools : % -base-tagged % -tools.Dockerfile % -pcp.repo % - tags.lis
220+ % -tools : % -base-tagged % -tools.Dockerfile % -tags.lis
220221 ./build-image tools $* $* -tags.lis
221222
222223% -tools.Dockerfile : Dockerfile.layered.j2 % -tags.lis
0 commit comments