Skip to content

Commit

Permalink
Added conditional for ExecStartPre=/usr/share/elasticsearch/bin/elast…
Browse files Browse the repository at this point in the history
…icsearch-systemd-pre-exec, as its only available on ES >=2.0
  • Loading branch information
jakommo committed Sep 20, 2016
1 parent a9f01fe commit 34f4c49
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions templates/systemd/elasticsearch.j2
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ WorkingDirectory={{es_home}}
User={{es_user}}
Group={{es_group}}

{% if es_version | version_compare('2.0', '>=') %}
ExecStartPre=/usr/share/elasticsearch/bin/elasticsearch-systemd-pre-exec
{% endif %}

ExecStart={{es_home}}/bin/elasticsearch \
-Des.pidfile=${PID_DIR}/elasticsearch.pid \
Expand Down

0 comments on commit 34f4c49

Please sign in to comment.