1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-26 20:55:19 +03:00
aports/community/elasticsearch/elasticsearch.post-upgrade
Jakub Jirutka 7c4e67edf9 community/elasticsearch: fix and improve init script
* SVCNAME is deprecated for a very long time, RC_SVCNAME should be used
* nice 0 is the default value, not needed to define
* error.log was previously owned by root instead of the ES user, so we need to fix it
2019-01-23 16:15:07 +01:00

11 lines
252 B
Bash

#!/bin/sh
ver_new="$1"
ver_old="$2"
if [ "$(apk version -t "$ver_old" "6.4.1-r1")" = "<" ]; then
chown elastico:elastico /var/log/elasticsearch/error.log 2>/dev/null
chown elastico:elastico /var/log/elasticsearch/*/error.log 2>/dev/null
fi
exit 0