Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not set cookie for prod node #2214

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion big_tests/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ else
TLS_DIST_OPTS :=
endif

COMMON_OPTS := -sname test -setcookie ejabberd -hidden \
COMMON_OPTS := -sname test -setcookie this_is_cookie_for_dev_nodes_only_do_not_use_it_on_production -hidden \
$(TLS_DIST_OPTS) \
-env REPO_DIR "$(ABS_REPO_DIR)" \
-env TEST_DIR "$(ABS_TEST_DIR)" \
Expand Down
2 changes: 1 addition & 1 deletion big_tests/test.config
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
%% See s2s_SUITE for example on using `hosts` to RPC into nodes (uses CT "require").
%% the Erlang node name of tested ejabberd/MongooseIM
{ejabberd_node, 'mongooseim@localhost'}.
{ejabberd_cookie, ejabberd}.
{ejabberd_cookie, 'this_is_cookie_for_dev_nodes_only_do_not_use_it_on_production'}.
{ejabberd_string_format, bin}.

%% TODO: in every new use case this should be used instead
Expand Down
10 changes: 5 additions & 5 deletions rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,15 @@
{overlay_vars, "rel/vars.config"},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]},
%% development nodes
{mim1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim1.vars.config"]},
{mim1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim1.vars.config", "rel/dev.vars.config"]},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]},
{mim2, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim2.vars.config"]},
{mim2, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim2.vars.config", "rel/dev.vars.config"]},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]},
{mim3, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim3.vars.config"]},
{mim3, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/mim3.vars.config", "rel/dev.vars.config"]},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]},
{fed1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/fed1.vars.config"]},
{fed1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/fed1.vars.config", "rel/dev.vars.config"]},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]},
{reg1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/reg1.vars.config"]},
{reg1, [{relx, [ {overlay_vars, ["rel/vars.config", "rel/reg1.vars.config", "rel/dev.vars.config"]},
{overlay, [{template, "rel/files/mongooseim.cfg", "etc/mongooseim.cfg"}]} ]}]}
]}.

Expand Down
1 change: 1 addition & 0 deletions rel/dev.vars.config
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{cluster_cookie, "this_is_cookie_for_dev_nodes_only_do_not_use_it_on_production"}.
4 changes: 3 additions & 1 deletion rel/files/vm.args
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
-sname {{node_name}}

## Cookie for distributed erlang
-setcookie ejabberd
## Please make sure this is randomly generated
## and different for all your MongooseIM or Erlang clusters.
-setcookie {{cluster_cookie}}

## Heartbeat management; auto-restarts VM if it dies or becomes unresponsive
## (Disabled by default..use with caution!)
Expand Down