From e642d1511ca34cfe5c35da6a732bc752cbd2400a Mon Sep 17 00:00:00 2001 From: David DeGraw Date: Mon, 30 Dec 2024 13:08:19 -0700 Subject: [PATCH] fix for new homebrew version from here: https://github.com/elastic/homebrew-tap/issues/150#issuecomment-1904701367 --- Formula/elasticsearch@6.rb | 39 +++++++------------------------------- 1 file changed, 7 insertions(+), 32 deletions(-) diff --git a/Formula/elasticsearch@6.rb b/Formula/elasticsearch@6.rb index 0f5ecdf..62c3c4d 100644 --- a/Formula/elasticsearch@6.rb +++ b/Formula/elasticsearch@6.rb @@ -86,37 +86,12 @@ def caveats Config: #{etc}/elasticsearch/ EOS end - - @plist_manual = "elasticsearch" - - def plist - <<~EOS - - - - - KeepAlive - - Label - #{plist_name} - ProgramArguments - - #{opt_bin}/elasticsearch - - EnvironmentVariables - - - RunAtLoad - - WorkingDirectory - #{var} - StandardErrorPath - #{var}/log/elasticsearch.log - StandardOutPath - #{var}/log/elasticsearch.log - - - EOS + + service do + run [opt_bin/"elasticsearch"] + working_dir var + log_path var/"log/elasticsearch.log" + error_log_path var/"log/elasticsearch.log" end test do @@ -156,4 +131,4 @@ def plist Process.kill(9, pid.read.to_i) end end -end \ No newline at end of file +end