Toggle navigation
Toggle navigation
This project
Loading...
Sign in
ops
/
yoho-ansible-roles
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
chunhua.zhang
5 years ago
Commit
82d076e129351d064a9233c0c32443b8d984d415
1 parent
a20bfd9b
bug fox
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletions
roles/openresty/files/java-nginx-config/nginx/conf/lua/limit_local_access.lua
roles/openresty/files/java-nginx-config/nginx/conf/lua/limit_local_access.lua
View file @
82d076e
...
...
@@ -27,7 +27,11 @@ local local_cidr = {
-- depends on $real_ip which setup by setup.lua
function
M
:
check_local_access
()
local
ip
=
string.gsub
(
ngx
.
var
.
remote_addr
,
"%s"
,
""
)
local
ip
=
ngx
.
var
.
real_ip
if
(
ip
==
nil
or
ip
==
''
)
then
return
false
end
local
is_local_ip
=
false
for
i
=
1
,
#
local_cidr
do
...
...
Please
register
or
login
to post a comment