Skip to content

Commit

Permalink
app-misc/elasticsearch: bump to 5.6.10
Browse files Browse the repository at this point in the history
Package-Manager: Portage-2.3.41, Repoman-2.3.9
  • Loading branch information
hydrapolic authored and mrueg committed Jul 11, 2018
1 parent 75fcbee commit ab5f42c
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 0 deletions.
1 change: 1 addition & 0 deletions app-misc/elasticsearch/Manifest
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
DIST elasticsearch-5.6.10.tar.gz 33796721 BLAKE2B 4e9d1d910a70acf32ca63cec811b711f692f3cf32dcec084a07f92d281eed07c067740bb5c5447055a6d0b6126e55a635edcd08c105dc59985db72bcd031a8a5 SHA512 17bd5710cfc3efa455428a79c74e63aacc9b9481d59a0b0df07ad4e4c25ef32dd41b3dbbde464a2801363b6d428a23eb52cc935640ce86bbc4d8a01dca8a1585
DIST elasticsearch-5.6.9.tar.gz 33794793 BLAKE2B a056443b1f71b3af773b5195147927017456e1c9a6517c549cfe7e4ec70f0ff4ec9363c9ef6376b7b942e82f811cd5927d44eb9f9eb8022a56e54a85b4ba7c46 SHA512 4e61a4c5f79d0439a414f1e9361f855cdb2f79322cf592bad43132605922fb8ded6368b01e05ef6bcbee49911943c2a3b6be5fd6d0900abddfe03c736cca96d6
DIST elasticsearch-6.2.4.tar.gz 29056810 BLAKE2B 121be27ac1db4fa6bbe285161b3f2b2dd889859b50f46b57b68ed43514568c4aa9629b5ca32edcc2328a6e7245256d64901c8acc8b2dd91337f8ca97b87c46e1 SHA512 9e6c0de8ed0d9e27fdd18ef7bada376af5a8680bb7a4f4d805926da456b349cee731ba90328b5eda5f0e62fa3f00f34646bf1c2b6c662d055f4be338d0690941
69 changes: 69 additions & 0 deletions app-misc/elasticsearch/elasticsearch-5.6.10.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

EAPI=6

inherit systemd user

DESCRIPTION="Open Source, Distributed, RESTful, Search Engine"
HOMEPAGE="https://www.elastic.co/products/elasticsearch"
SRC_URI="https://artifacts.elastic.co/downloads/${PN}/${P}.tar.gz"
LICENSE="Apache-2.0 BSD-2 LGPL-3 MIT public-domain"
SLOT="0"
KEYWORDS="~amd64"

RDEPEND="virtual/jre:1.8"

pkg_setup() {
enewgroup ${PN}
enewuser ${PN} -1 /bin/bash /usr/share/${PN} ${PN}
}

src_prepare() {
default

rm -v bin/*.{bat,exe} LICENSE.txt || die
}

src_install() {
keepdir /etc/${PN}
keepdir /etc/${PN}/scripts

insinto /etc/${PN}
doins -r config/.
rm -rv config || die

insinto /usr/share/${PN}
doins -r .

exeinto /usr/share/${PN}/bin
doexe "${FILESDIR}/elasticsearch-systemd-pre-exec"

chmod +x "${ED}"/usr/share/${PN}/bin/* || die

keepdir /var/{lib,log}/${PN}
fowners ${PN}:${PN} /var/{lib,log}/${PN}
fperms 0750 /var/{lib,log}/${PN}
dodir /usr/share/${PN}/plugins

insinto /etc/sysctl.d
newins "${FILESDIR}/${PN}.sysctl.d" ${PN}.conf

newconfd "${FILESDIR}/${PN}.conf.2" ${PN}
newinitd "${FILESDIR}/${PN}.init.2" ${PN}

systemd_newtmpfilesd "${FILESDIR}/${PN}.tmpfiles.d" ${PN}.conf
systemd_newunit "${FILESDIR}"/${PN}.service ${PN}.service
}

pkg_postinst() {
elog
elog "You may create multiple instances of ${PN} by"
elog "symlinking the init script:"
elog "ln -sf /etc/init.d/${PN} /etc/init.d/${PN}.instance"
elog
elog "Please make sure you put elasticsearch.yml, log4j2.properties and scripts"
elog "from /etc/elasticsearch into the configuration directory of the instance:"
elog "/etc/${PN}/instance"
elog
}

0 comments on commit ab5f42c

Please sign in to comment.