You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by sp...@apache.org on 2022/08/17 01:50:44 UTC
[apisix] branch master updated: change: remove deprecated apisix.real_ip_header (#7696)
This is an automated email from the ASF dual-hosted git repository.
spacewander pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git
The following commit(s) were added to refs/heads/master by this push:
new 1913ac238 change: remove deprecated apisix.real_ip_header (#7696)
1913ac238 is described below
commit 1913ac238bb6e8e342f115327c8de11838b9601a
Author: tzssangglass <tz...@gmail.com>
AuthorDate: Wed Aug 17 09:50:39 2022 +0800
change: remove deprecated apisix.real_ip_header (#7696)
---
apisix/cli/ngx_tpl.lua | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
diff --git a/apisix/cli/ngx_tpl.lua b/apisix/cli/ngx_tpl.lua
index db93cfdec..56f1d497a 100644
--- a/apisix/cli/ngx_tpl.lua
+++ b/apisix/cli/ngx_tpl.lua
@@ -348,10 +348,7 @@ http {
# error_page
error_page 500 @50x.html;
- {% if real_ip_header then %}
- real_ip_header {* real_ip_header *};
- {% print("\nDeprecated: apisix.real_ip_header has been moved to nginx_config.http.real_ip_header. apisix.real_ip_header will be removed in the future version. Please use nginx_config.http.real_ip_header first.\n\n") %}
- {% elseif http.real_ip_header then %}
+ {% if http.real_ip_header then %}
real_ip_header {* http.real_ip_header *};
{% end %}
@@ -359,12 +356,7 @@ http {
real_ip_recursive {* http.real_ip_recursive *};
{% end %}
- {% if real_ip_from then %}
- {% print("\nDeprecated: apisix.real_ip_from has been moved to nginx_config.http.real_ip_from. apisix.real_ip_from will be removed in the future version. Please use nginx_config.http.real_ip_from first.\n\n") %}
- {% for _, real_ip in ipairs(real_ip_from) do %}
- set_real_ip_from {*real_ip*};
- {% end %}
- {% elseif http.real_ip_from then %}
+ {% if http.real_ip_from then %}
{% for _, real_ip in ipairs(http.real_ip_from) do %}
set_real_ip_from {*real_ip*};
{% end %}