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

Remove RABBITMQ_ERLANG_COOKIE warning (backport #7391) #7395

Merged
merged 1 commit into from
Feb 23, 2023
Merged
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
Remove RABBITMQ_ERLANG_COOKIE warning
Fixes #7262

(cherry picked from commit b0d2f94)
  • Loading branch information
lukebakken authored and mergify[bot] committed Feb 23, 2023
commit 29ba1c3454a82e14f2609b95d01f4ed43ee8b973
25 changes: 0 additions & 25 deletions deps/rabbitmq_cli/lib/rabbitmq/cli/core/distribution.ex
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ defmodule RabbitMQ.CLI.Core.Distribution do

cookie ->
Node.set_cookie(cookie)
maybe_warn_about_deprecated_rabbitmq_erlang_cookie_env_variable(options)
:ok
end
end
Expand Down Expand Up @@ -111,28 +110,4 @@ defmodule RabbitMQ.CLI.Core.Distribution do
String.to_atom("rabbitmqcli-#{id}-#{rmq_hostname}")
end
end

defp maybe_warn_about_deprecated_rabbitmq_erlang_cookie_env_variable(options) do
case System.get_env("RABBITMQ_ERLANG_COOKIE") do
nil ->
:ok

_ ->
case Config.output_less?(options) do
true ->
:ok

false ->
warning =
ANSI.bright_red(
"RABBITMQ_ERLANG_COOKIE env variable support is deprecated and will be REMOVED in a future version. "
) <>
ANSI.yellow(
"Use the $HOME/.erlang.cookie file or the --erlang-cookie switch instead."
)

IO.puts(warning)
end
end
end
end