summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTony Vroon <chainsaw@gentoo.org>2018-01-08 12:52:18 +0000
committerTony Vroon <chainsaw@gentoo.org>2018-01-08 12:52:18 +0000
commitf709630fc7ee38948f67288fad113feae2ff75ba (patch)
tree93c4c24651eef6b2da86dd9e7d9f3f7fcd349c78 /app-misc/elasticsearch
parentmedia-video/simplescreenrecorder: Add missing DEPEND (diff)
downloadgentoo-f709630fc7ee38948f67288fad113feae2ff75ba.tar.gz
gentoo-f709630fc7ee38948f67288fad113feae2ff75ba.tar.bz2
gentoo-f709630fc7ee38948f67288fad113feae2ff75ba.zip
app-misc/elasticsearch: Most recent SugarCRM Enterprise supported release. Remove faulty release.
Package-Manager: Portage-2.3.13, Repoman-2.3.3
Diffstat (limited to 'app-misc/elasticsearch')
-rw-r--r--app-misc/elasticsearch/Manifest2
-rw-r--r--app-misc/elasticsearch/elasticsearch-1.7.6.ebuild (renamed from app-misc/elasticsearch/elasticsearch-1.7.5.ebuild)2
-rw-r--r--app-misc/elasticsearch/files/elasticsearch.init.164
3 files changed, 66 insertions, 2 deletions
diff --git a/app-misc/elasticsearch/Manifest b/app-misc/elasticsearch/Manifest
index 9ddccc402db1..15417d6ba11d 100644
--- a/app-misc/elasticsearch/Manifest
+++ b/app-misc/elasticsearch/Manifest
@@ -1,4 +1,4 @@
-DIST elasticsearch-1.7.5.tar.gz 28487351 BLAKE2B 96c18bf85378eecb330ed493794a448c0d3285d1c36d1add31d7840974d1a20516b0c008ce749249de105f6f6bd93b95bfd7f97ab02d4bb5d61ebf58060646ae SHA512 372e9edf5bd9f68c476e15276fc90cf2ecddbafde17fe803e6a50261c2d3a80616a9440d86494d8cfa411703f87cf053d31c62f4cdee260d64cdc0c07b5741ba
+DIST elasticsearch-1.7.6.tar.gz 28488767 BLAKE2B 0dc4fb10355e2139ee3a7e7e65366e8aa533b9714bf0f00d2bd8f4ef0669ba9f8f10dc5255c8c7a62abc0362e08ab5fda3c8b6b6f2bacfe5cce7255973293162 SHA512 2746f09b66919912e785c8d25c50ae74dbb38a41d99d9c926550786f9c2d7953d1ae1a54a32dae59a7269e5fbfa74dfbc91c3d412e415efd01c391ef7d329ba7
DIST elasticsearch-5.5.3.tar.gz 33486646 BLAKE2B 4f28d843b2daa73af1160436f9eedd20b9d91ee8d4454a210ad59c736c0ac0bd91384d972583d4de7e7dbc228b3e37546343da68545312333379298042ad8214 SHA512 013e238a3ccdb795b9472a6111ae804b770435776dfb703b379c34498591d3804e45fb27a7c473348917b4d9e6fde367184474680f1f72bbca129bf9644fb527
DIST elasticsearch-5.6.5.tar.gz 33780822 BLAKE2B 0541e27d7d9d18ec308495ab1cfb65c8f8e79960ef5d110ef5194a4033301b858a676c8c4d61f246e01ebc5679280c3eafe628e22ccfd84de9129f7a4606a041 SHA512 c3f31f561631c3f8df53cb49ac9a86dff3bcaa9e3ea2ac67dd959900ec1ddf676d307c9d8319ac51062072e506994934c61395049f6a6eac67e377d53517103f
DIST elasticsearch-6.0.1.tar.gz 28026460 BLAKE2B a70cd36affaccccf1ea552167e585a35cc748de1137cf4b23387798ae31b851104ccc19f8be83ecc645bcebfba344b5e55a397a9cbb0b380c4a118f1f0ffecf2 SHA512 b86a04acd194e7e96e3a32de6ab4983d6569ffb1714f2af9e2b49623004987e13e57c5db055153a188f5d2d7eea63d649fa87769f7625f3fc4923e0cd5b8f3ee
diff --git a/app-misc/elasticsearch/elasticsearch-1.7.5.ebuild b/app-misc/elasticsearch/elasticsearch-1.7.6.ebuild
index 8813d90d9d78..eca489c9bd2d 100644
--- a/app-misc/elasticsearch/elasticsearch-1.7.5.ebuild
+++ b/app-misc/elasticsearch/elasticsearch-1.7.6.ebuild
@@ -52,7 +52,7 @@ src_install() {
keepdir /var/{lib,log}/${MY_PN}
- newinitd "${FILESDIR}/elasticsearch.init.3" "${MY_PN}"
+ newinitd "${FILESDIR}/elasticsearch.init.1" "${MY_PN}"
newconfd "${FILESDIR}/${MY_PN}.conf.3" "${MY_PN}"
systemd_newunit "${FILESDIR}"/${PN}.service.2 "${PN}.service"
}
diff --git a/app-misc/elasticsearch/files/elasticsearch.init.1 b/app-misc/elasticsearch/files/elasticsearch.init.1
new file mode 100644
index 000000000000..c44671c95d1b
--- /dev/null
+++ b/app-misc/elasticsearch/files/elasticsearch.init.1
@@ -0,0 +1,64 @@
+#!/sbin/openrc-run
+
+name="Elasticsearch"
+description="Elasticsearch Server"
+
+ES_INSTANCE=${SVCNAME#*.}
+
+if [ -n "${ES_INSTANCE}" ] && [ ${SVCNAME} != "elasticsearch" ]; then
+ ES_BASE_PATH="/var/lib/elasticsearch/${ES_INSTANCE}"
+ CONF_DIR="/etc/elasticsearch/${ES_INSTANCE}"
+ LOG_DIR="/var/log/elasticsearch/${ES_INSTANCE}"
+else
+ ES_BASE_PATH="/var/lib/elasticsearch/_default"
+ CONF_DIR="/etc/elasticsearch"
+ LOG_DIR="/var/log/elasticsearch/_default"
+fi
+
+ES_DATA_PATH="${ES_BASE_PATH}/data"
+ES_WORK_PATH="${ES_BASE_PATH}/work"
+
+ES_HOME=${ES_HOME:="/usr/share/elasticsearch"}
+ES_USER=${ES_USER:="elasticsearch"}
+ES_GROUP=${ES_GROUP:="elasticsearch"}
+ES_STARTUP_SLEEP_TIME=${ES_STARTUP_TIME:=5}
+MAX_OPEN_FILES=${MAX_OPEN_FILES:=65536}
+MAX_MAP_COUNT=${MAX_MAP_COUNT:=262144}
+
+DATA_DIR=${DATA_DIR:="${ES_BASE_PATH}/data"}
+
+if [ -f "${CONF_DIR}/elasticsearch.in.sh" ]; then
+ ES_INCLUDE="${CONF_DIR}/elasticsearch.in.sh"
+fi
+
+export ES_INCLUDE
+export JAVA_HOME
+export JAVA_OPTS
+export ES_JVM_OPTIONS
+export ES_JAVA_OPTS
+export ES_STARTUP_SLEEP_TIME
+export ES_PATH_CONF="${CONF_DIR}"
+
+pidfile="/run/elasticsearch/${RC_SVCNAME}.pid"
+
+command="/usr/share/elasticsearch/bin/elasticsearch"
+command_args="-d --pidfile=${pidfile} -Des.default.path.conf=\"${CONF_DIR}\" -Des.default.path.data=\"${ES_DATA_PATH}\" -Des.default.path.work=\"${ES_WORK_PATH}\" -Des.default.path.logs=\"${LOG_DIR}\""
+command_user="${ES_USER}:${ES_GROUP}"
+required_files="${CONF_DIR}/elasticsearch.yml"
+retry="TERM/30/KILL/30"
+
+depend() {
+ use net
+}
+
+start_pre() {
+ if [ -n "${MAX_MAP_COUNT}" -a -f /proc/sys/vm/max_map_count ]; then
+ sysctl -q -w vm.max_map_count=${MAX_MAP_COUNT}
+ fi
+
+ checkpath -d -o "${ES_USER}:${ES_GROUP}" -m750 "/var/lib/elasticsearch"
+ checkpath -d -o "${ES_USER}:${ES_GROUP}" -m750 "/var/log/elasticsearch"
+ checkpath -d -o "${ES_USER}:${ES_GROUP}" -m750 "/run/elasticsearch"
+ checkpath -d -o "${ES_USER}:${ES_GROUP}" -m750 "${ES_BASE_PATH}"
+ checkpath -d -o "${ES_USER}:${ES_GROUP}" -m750 "${LOG_DIR}"
+}