commit: 1cdcb44523a8ea5608ca8a2f31ea6704539f347c
Author: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
AuthorDate: Wed Mar 12 20:32:30 2025 +0000
Commit: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
CommitDate: Wed Mar 12 20:32:30 2025 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1cdcb445
net-misc/exabgp: add 4.2.23
Signed-off-by: Patrick McLean <chutzpah <AT> gentoo.org>
net-misc/exabgp/Manifest | 1 +
net-misc/exabgp/exabgp-4.2.23.ebuild | 66 ++++++++++++++++++++++
...p-4.2.23-healthcheck-allow-disable-metric.patch | 22 ++++++++
3 files changed, 89 insertions(+)
diff --git a/net-misc/exabgp/Manifest b/net-misc/exabgp/Manifest
index 1d1bd126e5f8..f690ad9ff974 100644
--- a/net-misc/exabgp/Manifest
+++ b/net-misc/exabgp/Manifest
@@ -1 +1,2 @@
DIST exabgp-4.2.21.tar.gz 2933721 BLAKE2B
1d4b7cb6d053d2a9b8a338b6cf5f84d8d4ea2e1d1685cac8fb9b4b02cbdb8b9d5de41d4072d9379892e4bf89444f301f88243e5d5145d213956be7319861b723
SHA512
0efc7143191e8b557297e9329354c01e2418e0c4c45753941eba3a1f063e77d17a0efa7a14a3062764e45e709f0598f491c10e2c02e751590bb7c0943b61932b
+DIST exabgp-4.2.23.tar.gz 2935267 BLAKE2B
85b861e5ee318ecd6533386f8a298fdeabec161db9cba17f48957d1379ba0b30c3d9ea6c136e400c0ddf62595f7275d885d019bd6690fc7c58b65a112e6ce9e9
SHA512
03968997958dd1241c616b675bbea1e65d2660658205cf51f2bff6198c497a1379c949a61f9b93de4b91af2c0045eed54a94aa243fbca89c6d908bcb5811dc20
diff --git a/net-misc/exabgp/exabgp-4.2.23.ebuild
b/net-misc/exabgp/exabgp-4.2.23.ebuild
new file mode 100644
index 000000000000..6bfc13f8788d
--- /dev/null
+++ b/net-misc/exabgp/exabgp-4.2.23.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..13} )
+DISTUTILS_USE_PEP517=setuptools
+inherit tmpfiles systemd distutils-r1
+
+DESCRIPTION="The BGP swiss army knife of networking"
+HOMEPAGE="https://github.com/Exa-Networks/exabgp"
+SRC_URI="https://github.com/Exa-Networks/${PN}/archive/${PV}.tar.gz ->
${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ acct-group/exabgp
+ acct-user/exabgp
+"
+BDEPEND="
+ test? (
+ dev-python/psutil[${PYTHON_USEDEP}]
+ dev-python/six[${PYTHON_USEDEP}]
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}/exabgp-4.2.7-paths.patch"
+ "${FILESDIR}/exabgp-4.2.10-ip-path.patch"
+ "${FILESDIR}/exabgp-4.2.23-healthcheck-allow-disable-metric.patch"
+ "${FILESDIR}/exabgp-4.2.11-healthcheck-fix-log-crash.patch"
+ "${FILESDIR}/exabgp-4.2.11-less-verbose-logging.patch"
+
"${FILESDIR}/exabgp-4.2.21-exabgp.service-to-fix-socket-creation-on-start.patch"
+)
+
+distutils_enable_tests pytest
+
+python_test() {
+ ./qa/bin/parsing || die "parsing tests fail with ${EPYTHON}"
+ epytest
+}
+
+python_install_all() {
+ distutils-r1_python_install_all
+
+ newinitd "${FILESDIR}/${PN}.initd-r2" ${PN}
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+
+ newtmpfiles "${FILESDIR}/exabgp.tmpfiles" ${PN}.conf
+ systemd_dounit etc/systemd/*
+
+ insinto /etc/logrotate.d
+ newins "${FILESDIR}/${PN}.logrotate" ${PN}
+
+ keepdir /etc/exabgp
+
+ doman doc/man/*.?
+}
+
+pkg_postinst() {
+ tmpfiles_process ${PN}.conf
+}
diff --git
a/net-misc/exabgp/files/exabgp-4.2.23-healthcheck-allow-disable-metric.patch
b/net-misc/exabgp/files/exabgp-4.2.23-healthcheck-allow-disable-metric.patch
new file mode 100644
index 000000000000..67f9fcd89b98
--- /dev/null
+++ b/net-misc/exabgp/files/exabgp-4.2.23-healthcheck-allow-disable-metric.patch
@@ -0,0 +1,22 @@
+diff --git a/lib/exabgp/application/healthcheck.py
b/lib/exabgp/application/healthcheck.py
+index 7736cf40..1fda98d1 100644
+--- a/lib/exabgp/application/healthcheck.py
++++ b/lib/exabgp/application/healthcheck.py
+@@ -168,6 +168,7 @@ def parse():
+ g.add_argument(
+ "--start-ip", metavar='N', type=int, default=0, help="index of the
first IP in the list of IP addresses"
+ )
++ g.add_argument("--no-metric", action="store_true", default=False,
help="don't send metrics when updating announcements")
+ g.add_argument(
+ "--up-metric", metavar='M', type=int, default=100, help="first IP get
the metric M when the service is up"
+ )
+@@ -494,7 +495,8 @@ def loop(options):
+ announce = "route {0} next-hop {1}".format(str(ip),
options.next_hop or "self")
+
+ if command == "neighbor * announce":
+- announce = "{0} med {1}".format(announce, metric)
++ if not options.no_metric:
++ announce = "{0} med {1}".format(announce, metric)
+ if options.local_preference >= 0:
+ announce = "{0} local-preference {1}".format(announce,
options.local_preference)
+ if options.community or options.disabled_community: