Skip to content

Commit

Permalink
Merge pull request #975 from martincox/develop-3.0
Browse files Browse the repository at this point in the history
Change the chkconfig script to 'nodetool eval' with inline erlang
  • Loading branch information
ThomasArts authored May 13, 2019
2 parents 660862d + 74efdcc commit 8dcae40
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 13 deletions.
1 change: 0 additions & 1 deletion rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@
{template, "rel/files/riak-debug", "bin/riak-debug"},
{template, "rel/files/riak-chkconfig", "bin/riak-chkconfig"},
{template, "rel/files/riak-repl", "bin/riak-repl"},
{template, "rel/files/check_riak_config", "bin/check_riak_config"},

{copy, "rel/files/check_ulimit", "bin/hooks/check_ulimit"},
{copy, "rel/files/riak_not_running", "bin/hooks/riak_not_running"}
Expand Down
11 changes: 0 additions & 11 deletions rel/files/check_riak_config

This file was deleted.

13 changes: 12 additions & 1 deletion rel/files/riak-chkconfig
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,16 @@
## "vm.args = $VMARGS_PATH"
## "app.config = $CONFIG_PATH"

$ERTS_DIR/bin/escript $RELEASE_ROOT_DIR/bin/check_riak_config $CONFIG_PATH
CODE=" try
{ok, _} = file:consult(\"$CONFIG_PATH\"),
io:format(\"config is OK\\n\"),
halt(0)
catch
_:_ ->
io:format(\"Error reading ~p\\n\", [\"$CONFIG_PATH\"]),
halt(1)
end."

$BINDIR/erl -noshell -boot start_clean -eval "$CODE"

echo $CUTTLE_CONF

0 comments on commit 8dcae40

Please sign in to comment.