diff options
author | Stuart Shelton <stuart@shelton.me> | 2017-12-20 22:53:07 +0000 |
---|---|---|
committer | Stuart Shelton <stuart@shelton.me> | 2017-12-20 22:53:07 +0000 |
commit | b46d2181afe6b5ce544e032471a309f0adaeace0 (patch) | |
tree | 53bcd4837957a43f81da00b864a8d9ddf0d3629e /net-analyzer | |
parent | Add app-emulation/lxc-2.0.9, update app-emulation/lxc-2.0.7 (diff) | |
download | srcshelton-b46d2181afe6b5ce544e032471a309f0adaeace0.tar.gz srcshelton-b46d2181afe6b5ce544e032471a309f0adaeace0.tar.bz2 srcshelton-b46d2181afe6b5ce544e032471a309f0adaeace0.zip |
Add net-analyzer/netdata-1.9.0
Diffstat (limited to 'net-analyzer')
-rw-r--r-- | net-analyzer/netdata/Manifest | 2 | ||||
-rw-r--r-- | net-analyzer/netdata/netdata-1.9.0.ebuild | 208 |
2 files changed, 210 insertions, 0 deletions
diff --git a/net-analyzer/netdata/Manifest b/net-analyzer/netdata/Manifest index 3b21df8f..d514b1e1 100644 --- a/net-analyzer/netdata/Manifest +++ b/net-analyzer/netdata/Manifest @@ -8,6 +8,7 @@ DIST netdata-1.5.0.tar.gz 2257299 SHA256 8f66e40ba72ebf5c6e478197eaee3099823fd63 DIST netdata-1.6.0.tar.gz 2526589 SHA256 960dae3038be1aaf69fe1d1908d898f9a0c535a88362437772170a2979c1740b SHA512 9514fd320fc944897961f9581c123f37fb956dc3ae324a879744fabb0d853e8c6a1d62faf7a486f89a0507b2179f746e8dd0943443eb4744311e905a8c06aed6 WHIRLPOOL f90ca525817dbc3be9b18b8629c8093a32bb642e3d32fff77caf347aa7a6e48ce7b127b87fca43e99db62b7db8f0c2f6e8b4f61f3970256bf75fce6f59cc6977 DIST netdata-1.7.0.tar.gz 2646936 SHA256 ad57facc58f97f03cd2390ba2ffd253807fb641ec1afc390a81a4e4809287095 SHA512 f7204d77963c06c010b91fb9df47b79cc03070a730f0c09d599a0ec606510f449bab3c8429db2df1494e4cee330c2229300de010c3ec705fe91376d92adf48fd WHIRLPOOL 845b551aab019247b06612d769075b0dee5c4440f3cf2c8d46752f7ccb42b4d9db75d0cfa25279f72ebaf7230d6525e62012d583cba61a12f89fd5df7175a958 DIST netdata-1.8.0.tar.gz 2779648 SHA256 ca808a345ddf651669fdf53586d8296665d464f3cb25c4915276882d42914a73 SHA512 8bb21f49ce1fcf3d199eabd18f65d5005ef784b227f08cd8efe91e5cab2ae980cf0aea4bcaa3aca1dc666c10845684deca48257510ad574bd948ecd019afcdaf WHIRLPOOL 2e53a4de7617a018c092cea7d235497186ed0c9dffeae08befb1a5ebf25648c6529a01af9d7dc77b2ab2e4963f910deda7db81c73a4105c6af61b84a7dbb4560 +DIST netdata-1.9.0.tar.gz 2483847 SHA256 300289b39105167eae4616943c7c511d68a54bdd3541a845932e9f773cbf4213 SHA512 d17112e2222e48a7d06704d03598e6020b6172f93a6f19e5577657fc5ffe902b8a0472f53b880552eb653e855da3e743a863db446520af008d3b75fb1b438e90 WHIRLPOOL b77ac87314daf324ba2121b6a493e2dfc1a59608427758158f908ed0f7723d90774c414e9a5743c6e734b7cfa1df65ada6ced8b8ddfc9adfd19f99d0c1fd2724 EBUILD netdata-1.2.0-r1.ebuild 4101 SHA256 07d67cf03faffc23cecdb44df0420bd2cb4d5879a252584a1d58eddb21b6fc81 SHA512 32bcd5ff8e2c9c353686d5dfca76632864e4afbef7638e501cea324187fcd1b4fb8476b8c3a6075b9b5992c128881bf4a176d8aaef6fd185584962739d33a718 WHIRLPOOL d8958b202a51cff3720479033cc794ce27ca63fd26387a6c3ba245a0caddd0ab6940de8824d0eafc9a8e5dd584560a3eaec5ee8bc6104890f339ebb81b4a8446 EBUILD netdata-1.3.0.ebuild 4605 SHA256 c1d3a96ccc8fe1b0d308853bc27b28719f5b7df47ffba3613cf5e138c11de661 SHA512 557d157147d5c76e10145b714e0c9b19e58ecf1bfc21179727892c75375dd0c60375501b12ca9bddcbae8667ff95b209f872e6078394c67970c9b0e43c2542f6 WHIRLPOOL 1ce4ee7fa76d76174a55d88c705086cdc81bd4c60ad35aa82f04768ecb83d83be819c056af90259d476af7c0defd52ed7b28cdd4fc56f933b78412cd129cbc14 EBUILD netdata-1.4.0-r1.ebuild 4795 SHA256 7e4161b6fa5f82169233cdaef19057ab2e97f716d7d2429f9974c83e465cf911 SHA512 aaec94a718e24c96d5a37a64db490c3e336722c2fe34cb50d9ecf852ee21d84dc930b5cb65a30a371f94337b532ef7d526355ce851ee6af73310d7e94623c935 WHIRLPOOL c87ba7616f394547fec5a6e21a447d3b51793b6a7bd3e9ade59c20b5501d9b3d4223e9e7064cf2c0d66e51e7d5afc40d6a689af6b2d25d628d547ad4c7343449 @@ -16,4 +17,5 @@ EBUILD netdata-1.6.0.ebuild 5635 SHA256 7daaef9144613c52197152e4743be4864a5e79f5 EBUILD netdata-1.7.0.ebuild 5635 SHA256 7daaef9144613c52197152e4743be4864a5e79f5fb17da60b756a5a25d0ca9f0 SHA512 ab80f0e1166c20e635b3ec738924d97fbb03c6609cfc0d34e63301c3f1f8156b7b945120bc7f917e4fe53f3c3a6cae4c272d0136f7672b9dd7add41f03bd8708 WHIRLPOOL 5acbb2c3a69f7d7c15f93d5eb6a4cf5dd4fffd20edc370998ef118c9c5955693da6e75a25f816de76b62e12b9356f67879e150f75434eeed1f7ff526cea998f4 EBUILD netdata-1.8.0-r1.ebuild 5694 SHA256 27aa553dbe8aa24775df24d1ef59c8a97a3529b2d48894d36e8d22adf3c898fc SHA512 5173da77f0ebad818eeaf8c1b74cac8c2658869603fdf62da1d85bf73d0a2d04e404b981248a425f35e1e26bff286790d02049f5fba47cd2c24a5223df1b94e2 WHIRLPOOL 49384b08e02ceb948e1f6ac55b534251388ab91b2f85817e2c042fd0376dc4fd7a20848540f3cde4da54bf5062e7f5b5632bf37e4904012cb6b3d1b82f44083d EBUILD netdata-1.8.0.ebuild 5635 SHA256 7daaef9144613c52197152e4743be4864a5e79f5fb17da60b756a5a25d0ca9f0 SHA512 ab80f0e1166c20e635b3ec738924d97fbb03c6609cfc0d34e63301c3f1f8156b7b945120bc7f917e4fe53f3c3a6cae4c272d0136f7672b9dd7add41f03bd8708 WHIRLPOOL 5acbb2c3a69f7d7c15f93d5eb6a4cf5dd4fffd20edc370998ef118c9c5955693da6e75a25f816de76b62e12b9356f67879e150f75434eeed1f7ff526cea998f4 +EBUILD netdata-1.9.0.ebuild 5719 SHA256 49d4b4d2408b032ac0e6973b656b48d24111b5179623e6da158aceed886a9780 SHA512 2ca9bfe1ec6465a529804f49a41f8e3f229a8be2172e77f49253530568f5d01afbf2929f08864264b1b7f886e6074f46ae76729a0ec2c87658f0f400fba05e35 WHIRLPOOL 84560e7118ded3a475c7775151d881f1129abe45c75b36b67ef7cc9c8756332cd159fb168f2477e5dd2a2b25c3f59925ba04a31af633f36039d2316c20a0ec9b EBUILD netdata-9999.ebuild 5694 SHA256 27aa553dbe8aa24775df24d1ef59c8a97a3529b2d48894d36e8d22adf3c898fc SHA512 5173da77f0ebad818eeaf8c1b74cac8c2658869603fdf62da1d85bf73d0a2d04e404b981248a425f35e1e26bff286790d02049f5fba47cd2c24a5223df1b94e2 WHIRLPOOL 49384b08e02ceb948e1f6ac55b534251388ab91b2f85817e2c042fd0376dc4fd7a20848540f3cde4da54bf5062e7f5b5632bf37e4904012cb6b3d1b82f44083d diff --git a/net-analyzer/netdata/netdata-1.9.0.ebuild b/net-analyzer/netdata/netdata-1.9.0.ebuild new file mode 100644 index 00000000..00feb2a9 --- /dev/null +++ b/net-analyzer/netdata/netdata-1.9.0.ebuild @@ -0,0 +1,208 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 +PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} ) +WANT_AUTOCONF="2.5" # For autoconf-2.60+ + +inherit autotools fcaps linux-info python-r1 systemd user + +if [[ ${PV} == *9999 ]] ; then + EGIT_REPO_URI="https://github.com/firehol/${PN}.git" + inherit git-r3 +else + SRC_URI="https://github.com/firehol/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + KEYWORDS="~amd64 ~x86" + RESTRICT="mirror" +fi + +GIT_COMMIT="" +case "${PV}" in + 1.2.0) + GIT_COMMIT="bb4aa949f5ac825253d8adc6070661299abc1c3b" + ;; + 1.3.0) + GIT_COMMIT="b4591e87bd5bf5164eb55c90474bbb9f38f2dad4" + ;; + 1.4.0) + GIT_COMMIT="3028b87ee19e8550df6b9decc49733d595e0bd6e" + ;; + 1.5.0) + GIT_COMMIT="3bd41a09fccccbc6b095805556d3009b9ebf6213" + ;; + 1.6.0) + GIT_COMMIT="f5fa346a188e906a8f2cce3c2cf32a88ce81c666" + ;; + 1.7.0) + GIT_COMMIT="4016e2d9e3c2fcf5f6d59827bf5f81083d6645ba" + ;; + 1.8.0) + GIT_COMMIT="89ed309252981ddd50f697fde4fe93019cb3e652" + ;; + 1.9.0) + GIT_COMMIT="8e3e6627ccd97959d64bbb4df1f377a39c0e753f" + ;; +esac + +DESCRIPTION="Linux real time system monitoring, done right!" +HOMEPAGE="https://github.com/firehol/netdata https://my-netdata.io/" + +LICENSE="GPL-3+ MIT BSD" +SLOT="0" +IUSE="caps +compression fping ipmi mysql nfacct nodejs postgres +python systemd cpu_flags_x86_sse2" +REQUIRED_USE=" + mysql? ( python ) + python? ( ${PYTHON_REQUIRED_USE} )" +# Most unconditional dependencies are for plugins.d/charts.d.plugin: +RDEPEND=" + >=app-shells/bash-4:0 + || ( + net-analyzer/netcat6 + net-analyzer/netcat + ) + net-analyzer/tcpdump + net-analyzer/traceroute + net-misc/curl + net-misc/wget + sys-apps/util-linux + virtual/awk + caps? ( sys-libs/libcap ) + compression? ( sys-libs/zlib ) + fping? ( >=net-analyzer/fping-4.0 ) + ipmi? ( sys-libs/freeipmi ) + nfacct? ( + net-firewall/nfacct + net-libs/libmnl + ) + nodejs? ( net-libs/nodejs ) + python? ( + ${PYTHON_DEPS} + dev-python/pyyaml[${PYTHON_USEDEP}] + virtual/python-dnspython + virtual/python-ipaddress + mysql? ( + || ( + dev-python/mysqlclient[${PYTHON_USEDEP}] + dev-python/mysql-python[${PYTHON_USEDEP}] + ) + ) + postgres? ( dev-python/psycopg:2[${PYTHON_USEDEP}] ) + )" +DEPEND="${RDEPEND} + virtual/pkgconfig" + +# Check for Kernel-Samepage-Merging (CONFIG_KSM) +CONFIG_CHECK=" + ~KSM +" + +: ${NETDATA_USER:=${PN}} +: ${NETDATA_GROUP:=${PN}} + +FILECAPS=( + 'cap_dac_read_search,cap_sys_ptrace+ep' 'usr/libexec/netdata/plugins.d/apps.plugin' +) + +pkg_setup() { + linux-info_pkg_setup + + enewgroup "${NETDATA_GROUP}" + enewuser "${NETDATA_USER}" -1 -1 / "${NETDATA_USER}" +} + +src_prepare() { + default + + eautoreconf +} + +src_configure() { + econf \ + --localstatedir="${EPREFIX}"/var \ + --with-user="${NETDATA_USER}" \ + $(use_enable nfacct plugin-nfacct) \ + $(use_enable ipmi plugin-freeipmi) \ + $(use_enable cpu_flags_x86_sse2 x86-sse) \ + $(use_with compression zlib) +} + +src_install() { + default + + # Remove unneeded .keep files + find "${ED}" -name ".keep" -delete || die + + newdoc "${ED}"/usr/libexec/netdata/charts.d/README.md charts.md + newdoc "${ED}"/usr/libexec/netdata/plugins.d/README.md plugins.md + + if ! [[ -s "${ED}"/usr/share/netdata/web/version.txt && "$( < "${ED}"/usr/share/netdata/web/version.txt )" != '0' ]]; then + if [[ -n "${GIT_COMMIT:-}" ]]; then + einfo "Replacing packaged version '$( < "${ED}"/usr/share/netdata/web/version.txt )' with version '${GIT_COMMIT}'" + echo "${GIT_COMMIT}" > "${ED}"/usr/share/netdata/web/version.txt + else + ewarn "Removing packaged version file '/usr/share/netdata/web/version.txt' with version '$( < "${ED}"/usr/share/netdata/web/version.txt )'" + rm "${ED}"/usr/share/netdata/web/version.txt + fi + fi + + if ! use nodejs; then + rm -r "${ED}"/usr/libexec/netdata/node.d + rm "${ED}"/usr/libexec/netdata/plugins.d/node.d.plugin + fi + + rm -r "${ED}"/usr/share/netdata/web/old + rm 2>/dev/null \ + "${ED}"/usr/libexec/netdata/charts.d/README.md \ + "${ED}"/usr/libexec/netdata/node.d/README.md \ + "${ED}"/usr/libexec/netdata/plugins.d/README.md + rmdir -p "${ED}"/var/log/netdata "${ED}"/var/cache/netdata 2>/dev/null + + # Moved to init script + #fowners -Rc ${NETDATA_USER}:${NETDATA_GROUP} /var/log/netdata + #fowners -Rc ${NETDATA_USER}:${NETDATA_GROUP} /var/lib/netdata + + fowners -Rc root:"${NETDATA_GROUP}" /usr/share/"${PN}"/web || + die "Failed settings owners: ${?}" + + insinto /etc/netdata + doins system/netdata.conf + + #newinitd system/netdata-openrc "${PN}" + newinitd "${FILESDIR}"/"${PN}".initd "${PN}" + use systemd && systemd_dounit system/netdata.service +} + +pkg_postinst() { + if [[ -e "/sys/kernel/mm/ksm/run" ]]; then + if [[ "$( < /sys/kernel/mm/ksm/run )" != '1' ]]; then + elog "INFORMATION:" + echo + elog "I see you have kernel memory de-duper (called Kernel Same-page Merging," + elog "or KSM) available, but it is not currently enabled." + echo + elog "To enable it run:" + echo + elog "echo 1 >/sys/kernel/mm/ksm/run" + elog "echo 1000 >/sys/kernel/mm/ksm/sleep_millisecs" + echo + elog "If you enable it, you will save 20-60% of netdata memory." + fi + else + elog "INFORMATION:" + echo + elog "I see you do not have kernel memory de-duper (called Kernel Same-page" + elog "Merging, or KSM) available." + echo + elog "To enable it, you need a kernel built with CONFIG_KSM=y" + echo + elog "If you can have it, you will save 20-60% of netdata memory." + fi + + if ! use prefix; then + # This should be handled by FILECAPS, but wasn't... plus we want a + # fallback. + setcap cap_dac_read_search,cap_sys_ptrace+ep "${EROOT%/}"/usr/libexec/netdata/plugins.d/apps.plugin || + chmod 4755 "${EROOT%/}"/usr/libexec/netdata/plugins.d/apps.plugin || + eerror "Cannot set capabilities or SUID on '/usr/libexec/netdata/plugins.d/apps.plugin'" + fi +} |