Gentoo Archives: gentoo-commits

From: Amy Liffey <amynka@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/filebeat/
Date: Thu, 21 Sep 2017 14:59:22
Message-Id: 1506005911.ad60b775832549c239bd32a3e02c7c46cca27515.amynka@gentoo
1 commit: ad60b775832549c239bd32a3e02c7c46cca27515
2 Author: Tomas Mozes <hydrapolic <AT> gmail <DOT> com>
3 AuthorDate: Thu Sep 21 08:12:58 2017 +0000
4 Commit: Amy Liffey <amynka <AT> gentoo <DOT> org>
5 CommitDate: Thu Sep 21 14:58:31 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ad60b775
7
8 app-admin/filebeat: bump to 5.6.1
9
10 Closes:#5746
11
12 Package-Manager: Portage-2.3.10, Repoman-2.3.2
13
14 app-admin/filebeat/Manifest | 1 +
15 app-admin/filebeat/filebeat-5.6.1.ebuild | 69 ++++++++++++++++++++++++++++++++
16 2 files changed, 70 insertions(+)
17
18 diff --git a/app-admin/filebeat/Manifest b/app-admin/filebeat/Manifest
19 index 72139064c2a..77e4401adc4 100644
20 --- a/app-admin/filebeat/Manifest
21 +++ b/app-admin/filebeat/Manifest
22 @@ -1 +1,2 @@
23 DIST filebeat-5.5.2.tar.gz 18075191 SHA256 39e792324a35fe84ef9a63cd5324252bc71d1c665188e8d597e12ca170cfde7a SHA512 ad92b41a9ceaad6c6e6fc80d0adccd7fe03a7056d121484bcf35c6a46b2061a5ef6d32121dd12d59b51e7678769da5c405b1d549fa130631ae3f1989b78fba48 WHIRLPOOL 46d182bd339abd26f3c4cf3f8d3a716180fc00147458f571eec34aefcaa67d9e88a561988e37c47083528024e4e0559b255c7a17efa43e0e4b21b653a575f7fd
24 +DIST filebeat-5.6.1.tar.gz 18142175 SHA256 3534ef7a3833ae85aef53a12580520b5d85feaa1408289ea37a6ebff5a2fda0a SHA512 842fd28012455ddacffb66db719e1df6fe987c844899d34428d65bca2ec4e1b49a801a976f546b4380da077426250109c5b1c84188a44c14c98f054165b27123 WHIRLPOOL 1d11e08572e51c526cd0443b3fe3ce691dbcd8bc5463a531d89d2685df157f61e28ca645c37f273e7f5b7c69984f5152de310a140567cd757b70a68d0bc578aa
25
26 diff --git a/app-admin/filebeat/filebeat-5.6.1.ebuild b/app-admin/filebeat/filebeat-5.6.1.ebuild
27 new file mode 100644
28 index 00000000000..451e2191c7a
29 --- /dev/null
30 +++ b/app-admin/filebeat/filebeat-5.6.1.ebuild
31 @@ -0,0 +1,69 @@
32 +# Copyright 1999-2017 Gentoo Foundation
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=6
36 +
37 +DESCRIPTION="Lightweight log shipper for Logstash and Elasticsearch"
38 +HOMEPAGE="https://www.elastic.co/products/beats"
39 +SRC_URI="https://github.com/elastic/beats/archive/v${PV}.tar.gz -> ${P}.tar.gz"
40 +
41 +LICENSE="Apache-2.0"
42 +SLOT="0"
43 +KEYWORDS="~amd64 ~x86"
44 +
45 +DEPEND=">=dev-lang/go-1.8.3"
46 +RDEPEND="!app-admin/filebeat-bin"
47 +
48 +ELASTIC="${WORKDIR}/src/github.com/elastic"
49 +BEATS="${ELASTIC}/beats"
50 +S="${BEATS}"
51 +
52 +src_unpack() {
53 + mkdir -p "${ELASTIC}" || die
54 + unpack ${P}.tar.gz
55 + mv beats-${PV} "${BEATS}" || die
56 +}
57 +
58 +src_compile() {
59 + cd ${BEATS}/filebeat || die
60 + GOPATH="${WORKDIR}" emake
61 +}
62 +
63 +src_test() {
64 + cd ${BEATS}/filebeat || die
65 + GOPATH="${WORKDIR}" emake check
66 +}
67 +
68 +src_install() {
69 + keepdir /var/{lib,log}/${PN}
70 +
71 + fperms 0750 /var/{lib,log}/${PN}
72 +
73 + newconfd "${FILESDIR}/${PN}.confd" ${PN}
74 + newinitd "${FILESDIR}/${PN}.initd" ${PN}
75 +
76 + insinto "/usr/share/doc/${PF}/examples"
77 + doins ${PN}/{filebeat.yml,filebeat.full.yml}
78 +
79 + insinto "/etc/${PN}"
80 + doins ${PN}/{filebeat.template.json,filebeat.template-es2x.json,filebeat.template-es6x.json}
81 +
82 + exeinto "/usr/share/${PN}"
83 + doexe libbeat/scripts/migrate_beat_config_1_x_to_5_0.py
84 +
85 + dobin filebeat/filebeat
86 +}
87 +
88 +pkg_postinst() {
89 + if [[ -n "${REPLACING_VERSIONS}" ]]; then
90 + elog "Please read the migration guide at:"
91 + elog "https://www.elastic.co/guide/en/beats/libbeat/5.0/upgrading.html"
92 + elog ""
93 + elog "The migration script:"
94 + elog "${EROOT%/}/usr/share/filebeat/migrate_beat_config_1_x_to_5_0.py"
95 + elog ""
96 + fi
97 +
98 + elog "Example configurations:"
99 + elog "${EROOT%/}/usr/share/doc/${PF}/examples"
100 +}