tokers commented on a change in pull request #4540:
URL: https://github.com/apache/apisix/pull/4540#discussion_r664987154
##########
File path: apisix/cli/ops.lua
##########
@@ -443,15 +477,17 @@ Please modify "admin_key" in conf/config.yaml .
for index, value in ipairs(yaml_conf.apisix.node_listen) do
if type(value) == "number" then
- if value == control_port then
- util.die("control port conflicts with node_listen port\n")
+ if ports_to_check[value] ~= nil then
+ util.die("node_listen port ", value, " conflicts with ",
+ ports_to_check[value], "\n")
end
table_insert(node_listen, index, {port = value})
elseif type(value) == "table" then
- if type(value.port) == "number" and value.port == control_port
then
- util.die("control port conflicts with node_listen port\n")
+ if type(value.port) == "number" and ports_to_check[value.port]
~= nil then
+ util.die("node_listen port ", value.port, " conflicts with
",
+ ports_to_check[value.port], "\n")
Review comment:
Ditto.
##########
File path: apisix/cli/ops.lua
##########
@@ -443,15 +477,17 @@ Please modify "admin_key" in conf/config.yaml .
for index, value in ipairs(yaml_conf.apisix.node_listen) do
if type(value) == "number" then
- if value == control_port then
- util.die("control port conflicts with node_listen port\n")
+ if ports_to_check[value] ~= nil then
+ util.die("node_listen port ", value, " conflicts with ",
+ ports_to_check[value], "\n")
Review comment:
Bad indent.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]